2

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.

Alex
  • 19,533
  • 37
  • 126
  • 195
  • 1
    This is not at all a duplicate of the linked question. It is a duplicate of https://stackoverflow.com/q/55990574/2954547 instead. – shadowtalker Jul 14 '22 at 01:29

0 Answers0