Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ADD a 'move_apply' function #452

Open
paulinesimon97 opened this issue Jun 10, 2024 · 0 comments
Open

ADD a 'move_apply' function #452

paulinesimon97 opened this issue Jun 10, 2024 · 0 comments
Labels

Comments

@paulinesimon97
Copy link

The idea
With bottleneck move_mean, I can compute more effectively the result of the pandas rolling().mean() chain. It could be good to have an equivalent for rolling().apply(fct,kwargs).

Expected behavior
Then, we will have the possibility to compute any function with a moving window and particularly statistical metrics (mean square error, median square error, mean absolute error...).

Additional context
I would be particularly interested in computing a moving mean square error:
Arguments:

  • data = array of size N
  • ref = array of size M <N (given as argument)
  • window of size M
    moving function to compute: mean((data[window]-ref)**2)

I don't know how to code in C so I cannot implement the function myself. Can someone do it, please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants