ENH: Change default behavior of rolling.count to be consistent with others #31302
Labels
API - Consistency
Internal Consistency of API/Behavior
Deprecate
Functionality to remove in pandas
Window
rolling, ewma, expanding
Milestone
Following on discussion happened in #30923, we may want to change the default behavior of
rolling.count
with regards to its parametermin_periods
, so it is consistent with all other similar APIs such asrolling.mean
androlling.sum
.Code Sample
With the updates from #30923
Expected Output
Problem description
With the updates from #30923, the
min_periods
argument ofrolling.count
is now respected (it used to be completely ignored). However, the default value remains 0 for backward compatibility purpose. In future updates we probably want to change this default behavior so it's consistent with other similar APIs.@mroeschke previously mentioned we needed to start with a
DeprecationWarning
to inform users of future changes, then probably in the following release make the actual change.@jreback @WillAyd
Let me know what you guys think!
The text was updated successfully, but these errors were encountered: