Signature Description Parameters
template<typename F, typename T, typename ... Ts>
DataFrame
groupby (F &&func, const char *gb_col_name = nullptr, sort_state already_sorted = sort_state::not_sorted) const;
Groupby copies the DataFrame into a temp DataFrame and sorts the temp df by gb_col_name before performing groupby. If gb_col_name is null, it groups by index. F: type functor to be applied to columns to group by
T: type of the groupby column. In case of index, it is type of index
Ts: List of the types of all data columns. A type should be specified in the list only once.
func: The functor to do the groupby. Specs for the functor is in a separate doc.
already_sorted: If the DataFrame is already sorted by gb_col_name, this will save the expensive sort operation
template<typename F, typename T, typename ... Ts>
std::future<DataFrame>
groupby_async (F &&func, const char *gb_col_name = nullptr, sort_state already_sorted = sort_state::not_sorted) const;
Same as groupby() above, but executed asynchronously