Timeline for How to convert a Dataset into an indexed dataset / association-of-associations given a column header?
Current License: CC BY-SA 4.0
9 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Nov 23, 2020 at 12:43 | comment | added | Anton Antonov | @IntroductionToProbability, sounds good. | |
| Nov 23, 2020 at 11:02 | vote | accept | IntroductionToProbability | ||
| Nov 23, 2020 at 11:02 | comment | added | IntroductionToProbability | I missed WReach reply initially and will select this as the answer as it does not involve converting back to normal and is the fastest answer. | |
| Nov 20, 2020 at 13:22 | comment | added | Anton Antonov | @WReach I updated my answer with your suggestion. (It is also faster.) | |
| Nov 20, 2020 at 13:21 | history | edited | Anton Antonov | CC BY-SA 4.0 | Update the definition of f per WReach suggestion. |
| Nov 19, 2020 at 14:10 | comment | added | kickert | I went with a similiar riff on what Anton did: f[ds_, col_] := Dataset[AssociationThread[ Normal@ds[[All, col]] -> Normal[KeyDrop[ds, col]]]] | |
| Nov 19, 2020 at 10:31 | comment | added | IntroductionToProbability | This appears the fastest answer despite converting to Normal and then Dataset | |
| Nov 19, 2020 at 4:50 | comment | added | WReach | +1. Similarly, ds[Apply[Association], #[ch] -> KeyDrop[#, ch]&] | |
| Nov 18, 2020 at 17:07 | history | answered | Anton Antonov | CC BY-SA 4.0 |