I created a dateset (estimates) with 25 keys (my columns), and about a hundred rows. I'd like to be able to list the keys from the dataset.
I did this:
estimates[Keys]
which returned:
I also tried:
estimates[1]
which returned:
How can I display the entire list of keys?
My code is below:
Module[
{fileTemp, header, data},
fileTemp = Import[NotebookDirectory[] <> "test.xlsx", {"Sheets", "estimates"}];
header = fileTemp[[1]];
data = fileTemp[[2 ;;]];
estimates = Dataset@Map[AssociationThread[header, #] &]@data;
]
The following is part of the Excel sheet:
estimates[Keys]
worked when I get an error: "Cannot apply Keys to an expression of the form {__Association}" -- would you please check to see if e.g.titanic[Keys]
works on your system, using the definition from my answer? $\endgroup$