The documentation (10.0.2) indicates that Grid can be used to display a Dataset; the section in guide/ComputationWithStructuredDatasets labelled 'Dataset Presentation'. However simply invoking Grid[aDataset] echos Grid wrapped around the Dataset.

e.g. Grid[Dataset[{Association["a" -> 1, "b" -> 2], Association["a" -> 3, "b" -> 4]}]]

Is there trick I'm missing here or is the documentation just misleading or out of date (in either direction; functionality not yet implemented)?


My guess is that the documentation is listing Grid, Column, etc for Dataset Presentation in a generic sense. By that I mean that those functions have no special behaviour defined for dataset objects, but they are useful to visualize the kinds of data that we are likely to find in datasets.

For example, we can use some of those presentation functions in conjunction with the dataset in the question like this:

dataset = Dataset[{Association["a" -> 1, "b" -> 2], Association["a" -> 3, "b" -> 4]}]

dataset screenshot

dataset[Grid, Values]

grid screenshot

dataset[Column, MenuView]

column/menuview screenshot

dataset[Row, TabView]

row/tabview screenshot

  • 1
    $\begingroup$ That (dataset[Grid, Values]) is 90% of what I was after. It would be nice if the column headings could be persuaded to appear. $\endgroup$
    – Ymareth
    Mar 12 '15 at 8:58

Without knowing where in the help you saw it, its hard to interpret the full context but Grid can certainly be used to arrange datasets :

someDS = {<|"ID" -> 1, "Value" -> 100|>, <|"ID" -> 2, 
 "Value" -> 250|>} // Dataset;

Grid[{{someDS, someDS}, {someDS, someDS}}]

Gridded DS

Although this is the literal answer - I suspect you were looking for something a little more revealing?

  • $\begingroup$ Here's a online link... reference.wolfram.com/language/guide/…. About 2/3 of the way down. In your example Grid is showing Datasets in the grid, I want the Dataset (well a 2-D one) unpacked into the grid. $\endgroup$
    – Ymareth
    Mar 11 '15 at 16:38
  • $\begingroup$ @Ymareth I think you're correct in assuming its either for forthcoming functionality or simply my answer or a mistake. There dont seem to be any sections marked "new" in any of their help pages, and I had a good scan on Columns and couldn't find any references to Dataset. $\endgroup$ Mar 11 '15 at 21:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.