def groupby(self, to_groupby):
        return self._groupby(self.values, _values_from_object(to_groupby))
Group the index labels by a given array of values.
dataset/ETHPy150Open pydata/pandas/pandas/indexes/base.py/Index.groupby