Pandas has a df.rolling(N).apply(f) functionality that applies f to each column of df using a rolling window of size N. However, how can I apply a rolling function on the entire dataframe? That is, rather than f receiving each column of df one at a time, I would like all the columns to be passed to f like the way df.apply(f) would do.
- 1This is not at all a duplicate of the linked question. It is a duplicate of stackoverflow.com/q/55990574/2954547 instead.shadowtalker– shadowtalker2022-07-14 01:29:08 +00:00Commented Jul 14, 2022 at 1:29
Add a comment |