def _delegate_method(self, name, *args, **kwargs):
    from pandas import Series
    method = getattr(self._parent, name)
    res = method(*args, **kwargs)
    if (res is not None):
        return Series(res, index=self.index, name=self.name)
def _delegate_method(self, name, *args, **kwargs):
    from pandas import Series
    method = getattr(self._parent, name)
    res = method(*args, **kwargs)
    if (res is not None):
        return Series(res, index=self.index, name=self.name)