scipp.groupby#

scipp.groupby(data, /, group, *, bins=None)#

Group dataset or data array based on values of specified labels.

Parameters:
  • data (DataArray | Dataset) – Input data to reduce.

  • group (Variable | str) – Name of labels to use for grouping or Variable to use for grouping

  • bins (Optional[Variable], default: None) – Optional bins for grouping label values.

Returns:

GroupByDataArray | GroupByDataset – GroupBy helper object.