I'm looking for a neater way to achieve this, which to me looks awkward and suggests that I am missing something...
Given a Dataset...
ds = Dataset[{
<|"a"->1,"b"->1,"c"->3|>,
<|"a"->1,"b"->2,"c"->4|>,
<|"a"->2,"b"->3,"c"->5|>}];
Return another Dataset given by the grouping by one column and the maximal by another...
ds[GroupBy[#a &], MaximalBy[#b &]] // Values // Flatten
To return...
Dataset[{<|"a" -> 1, "b" -> 2, "c" -> 4|>, <|"a" -> 2, "b" -> 3, "c" -> 5|>}
The GroupBy and MaximalBy return a list of Associations of row number to a List of Associations (of which there is only one) which then needs (something like) //Values//Flatten to retrieve the Dataset I want.
Is there a more Dataset-eque way of doing this?