I currently have a dataset, and I would like to add a column based on another list.
For example:
ds = Dataset[{<|"name" -> "bob"|>, <|"name" -> "joe"|>}];
ages = {1,2};
I want to get
Dataset[{<|"name" -> "bob", "age"->1|>, <|"name" -> "joe", "age"->2|>}];
I was thinking of using MapIndex, but I don't really know how to make reform the results into a dataset again, and it seems wasteful.
How can I do this?