def resample(self, by): ''' Group DataFrame by date time index. :param by: Used to determine the groups for the groupby. :returns: GroupBy object ''' gb = self._dataframe.groupByIndex(by) return groupby.GroupBy(gb)
def resample(self, by): ''' Group series by date time index. :param by: Used to determine the groups for the groupby. :returns: GroupBy object. ''' gb = self._series.resample(by) return groupby.GroupBy(gb)
def groupby(self, by=None): ''' Group Series. :param by: Used to determine the groups for the groupby. :returns: GroupBy object. ''' gb = self._series.groupBy(by) return groupby.GroupBy(gb)
def groupby(self, by): ''' Group DataFrame. :param by: Period string. :returns: GroupBy object. ''' if isinstance(by, basestring): by = [by] gb = self._dataframe.groupBy(by) return groupby.GroupBy(gb)