(self, periods=1, freq=None, axis=0)
| 2016 | |
| 2017 | @derived_from(pd.DataFrame) |
| 2018 | def shift(self, periods=1, freq=None, axis=0): |
| 2019 | if not isinstance(periods, Integral): |
| 2020 | raise TypeError("periods must be an integer") |
| 2021 | |
| 2022 | axis = _validate_axis(axis) |
| 2023 | if axis == 0: |
| 2024 | return new_collection(Shift(self, periods, freq)) |
| 2025 | |
| 2026 | return self.map_partitions( |
| 2027 | func=Shift.func, |
| 2028 | enforce_metadata=False, |
| 2029 | transform_divisions=False, |
| 2030 | periods=periods, |
| 2031 | axis=axis, |
| 2032 | freq=freq, |
| 2033 | ) |
| 2034 | |
| 2035 | @derived_from(pd.DataFrame) |
| 2036 | def diff(self, periods=1, axis=0): |
nothing calls this directly
no test coverage detected