6
$\begingroup$

I'm loving the fact that Mathematica has finally implemented the Dataset feature, but I'm still struggling a little with it. I have a Dataset that contains a bunch of functions for different diseases that looks like this:initial dataset

Now I would like to use the list of diseases separately as a list. Extracting a single element works fine, for example:

RRTable[[1,"Cause"]]

returns the String "Oral Cavity and Pharynx Cancer"

However, extracting the whole column by using:

RRTable[[All,"Cause"]]

returns another Dataset: output of column selection

And I cannot find a way to transform this into a list that contains just the list. Any idea on how to do that? Sorry if this is simple but I've been browsing the documentation of Dataset for quite some time now...

$\endgroup$

closed as off-topic by m_goldberg, MarcoB, dr.blochwave, user9660, b.gates.you.know.what Oct 23 '15 at 7:08

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – m_goldberg, MarcoB, dr.blochwave, Community, b.gates.you.know.what
If this question can be reworded to fit the rules in the help center, please edit the question.

  • $\begingroup$ Have you tried Normal[RRTable[[All,"Cause"]]]; where Head[Normal[RRTable[[All,"Cause"]]]] returns List. $\endgroup$ – Hans Oct 23 '15 at 0:49
  • $\begingroup$ Brilliant! I was completely unaware of the "Normal" function! Thanks! I feel this is going to help me a lot in more than one context! $\endgroup$ – Moppentapper Oct 23 '15 at 0:53
11
$\begingroup$

Try

Normal[RRTable[[All,"Cause"]]]

where

Head[Normal[RRTable[[All,"Cause"]]]]

returns List

$\endgroup$

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