Skip to content

BUG: window functions count should be an integer dtype #12538

Closed
@jreback

Description

@jreback
In [1]: df = DataFrame({'A' : pd.date_range('20130101',periods=3),'B' : range(3)})

In [2]: df.rolling(window=2).count()
Out[2]: 
     A    B
0  1.0  1.0
1  2.0  2.0
2  2.0  2.0

In [3]: df.rolling(window=2).count().dtypes
Out[3]: 
A    float64
B    float64
dtype: object

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions