CLN: ASV rolling benchmark
State: closed

The benchmark was simplified by parameterizing over the various statistical methods and constructors (Series and DataFrame). I made a separate class for `Quantile` since various quantiles were benchmarked. I figured benchmarking 10^4 points and 10^5 points is a little redundant, so I am just benchmarking 10^5 here.  

Labels:
name: Clean
name: Benchmark
description: Performance (ASV) benchmarks

Comments:
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=h1) Report
> Merging [#18725](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/ae74c2b11580af2e6636f24871e0bc331fd4fad5?src=pr&el=desc) will **increase** coverage by `<.01%`.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/18725/graphs/tree.svg?height=150&width=650&token=eZ4WkYLtcO&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #18725      +/-   ##
==========================================
+ Coverage    91.6%    91.6%   +<.01%     
==========================================
  Files         153      153              
  Lines       51306    51306              
==========================================
+ Hits        46998    46999       +1     
+ Misses       4308     4307       -1
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `89.46% <ø> (+0.01%)` | :arrow_up: |
| #single | `40.72% <ø> (-0.12%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/io/gbq.py](https://codecov.io/gh/pandas-dev/pandas/pull/18725/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL2dicS5weQ==) | `25% <0%> (-58.34%)` | :arrow_down: |
| [pandas/util/testing.py](https://codecov.io/gh/pandas-dev/pandas/pull/18725/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvdGVzdGluZy5weQ==) | `82.34% <0%> (-0.2%)` | :arrow_down: |
| [pandas/core/frame.py](https://codecov.io/gh/pandas-dev/pandas/pull/18725/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZnJhbWUucHk=) | `97.81% <0%> (-0.1%)` | :arrow_down: |
| [pandas/plotting/\_converter.py](https://codecov.io/gh/pandas-dev/pandas/pull/18725/diff?src=pr&el=tree#diff-cGFuZGFzL3Bsb3R0aW5nL19jb252ZXJ0ZXIucHk=) | `66.52% <0%> (+1.73%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=footer). Last update [ae74c2b...0c51b40](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=h1) Report
> Merging [#18725](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/99d384d4f7ef6e2b6cb5a4eebea127e8bddf521b?src=pr&el=desc) will **increase** coverage by `<.01%`.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/18725/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #18725      +/-   ##
==========================================
+ Coverage   91.59%   91.59%   +<.01%     
==========================================
  Files         153      153              
  Lines       51361    51361              
==========================================
+ Hits        47043    47046       +3     
+ Misses       4318     4315       -3
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `89.46% <ø> (+0.02%)` | :arrow_up: |
| #single | `40.73% <ø> (-0.12%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/io/gbq.py](https://codecov.io/gh/pandas-dev/pandas/pull/18725/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL2dicS5weQ==) | `25% <0%> (-58.34%)` | :arrow_down: |
| [pandas/core/frame.py](https://codecov.io/gh/pandas-dev/pandas/pull/18725/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZnJhbWUucHk=) | `97.81% <0%> (-0.1%)` | :arrow_down: |
| [pandas/plotting/\_converter.py](https://codecov.io/gh/pandas-dev/pandas/pull/18725/diff?src=pr&el=tree#diff-cGFuZGFzL3Bsb3R0aW5nL19jb252ZXJ0ZXIucHk=) | `66.52% <0%> (+1.73%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=footer). Last update [99d384d...5e1a79b](https://codecov.io/gh/pandas-dev/pandas/pull/18725?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

lgtm. can you show this runs.
Here's the run of `rolling.py`

@jorisvandenbossche added `Dataframe.rolling` benchmarks to `gil.py`
```
asv dev -b ^rolling
· Discovering benchmarks
· Running 2 total benchmarks (1 commits * 1 environments * 2 benchmarks)
[  0.00%] ·· Building for existing-py_home_matt_anaconda_envs_pandas_dev_bin_python
[  0.00%] ·· Benchmarking existing-py_home_matt_anaconda_envs_pandas_dev_bin_python
[ 50.00%] ··· Running rolling.Methods.time_rolling                                                     ok
[ 50.00%] ···· 
               ============ ======== ======= ======== ========
                contructor   window   dtype   method          
               ------------ -------- ------- -------- --------
                DataFrame      10      int    median   80.0ms 
                DataFrame      10      int     mean    5.88ms 
                DataFrame      10      int     max     5.65ms 
                DataFrame      10      int     min     5.73ms 
                DataFrame      10      int     std     6.03ms 
                DataFrame      10      int    count    7.94ms 
                DataFrame      10      int     skew    6.84ms 
                DataFrame      10      int     kurt    6.99ms 
                DataFrame      10      int     sum     4.91ms 
                DataFrame      10      int     corr    55.2s  
                DataFrame      10      int     cov     54.6s  
                DataFrame      10     float   median   84.4ms 
                DataFrame      10     float    mean    5.13ms 
                DataFrame      10     float    max     7.36ms 
                DataFrame      10     float    min     6.66ms 
                DataFrame      10     float    std     6.63ms 
                DataFrame      10     float   count    7.82ms 
                DataFrame      10     float    skew    9.65ms 
                DataFrame      10     float    kurt    10.0ms 
                DataFrame      10     float    sum     4.83ms 
                DataFrame      10     float    corr    54.8s  
                DataFrame      10     float    cov     54.6s  
                DataFrame     1000     int    median   112ms  
                DataFrame     1000     int     mean    5.91ms 
                DataFrame     1000     int     max     5.73ms 
                DataFrame     1000     int     min     5.80ms 
                DataFrame     1000     int     std     6.27ms 
                DataFrame     1000     int    count    7.90ms 
                DataFrame     1000     int     skew    6.88ms 
                DataFrame     1000     int     kurt    7.05ms 
                DataFrame     1000     int     sum     4.95ms 
                DataFrame     1000     int     corr    55.0s  
                DataFrame     1000     int     cov     54.7s  
                DataFrame     1000    float   median   144ms  
                DataFrame     1000    float    mean    5.10ms 
                DataFrame     1000    float    max     7.01ms 
                DataFrame     1000    float    min     6.98ms 
                DataFrame     1000    float    std     6.66ms 
                DataFrame     1000    float   count    7.87ms 
                DataFrame     1000    float    skew    9.55ms 
                DataFrame     1000    float    kurt    9.88ms 
                DataFrame     1000    float    sum     4.75ms 
                DataFrame     1000    float    corr    54.6s  
                DataFrame     1000    float    cov     54.9s  
                  Series       10      int    median   82.0ms 
                  Series       10      int     mean    8.11ms 
                  Series       10      int     max     8.65ms 
                  Series       10      int     min     8.88ms 
                  Series       10      int     std     9.00ms 
                  Series       10      int    count    14.6ms 
                  Series       10      int     skew    8.36ms 
                  Series       10      int     kurt    8.30ms 
                  Series       10      int     sum     7.95ms 
                  Series       10      int     corr    91.3ms 
                  Series       10      int     cov     58.4ms 
                  Series       10     float   median   86.4ms 
                  Series       10     float    mean    7.88ms 
                  Series       10     float    max     9.51ms 
                  Series       10     float    min     9.46ms 
                  Series       10     float    std     9.55ms 
                  Series       10     float   count    14.6ms 
                  Series       10     float    skew    12.4ms 
                  Series       10     float    kurt    12.7ms 
                  Series       10     float    sum     7.46ms 
                  Series       10     float    corr    86.0ms 
                  Series       10     float    cov     57.2ms 
                  Series      1000     int    median   115ms  
                  Series      1000     int     mean    8.14ms 
                  Series      1000     int     max     8.60ms 
                  Series      1000     int     min     8.63ms 
                  Series      1000     int     std     9.01ms 
                  Series      1000     int    count    14.6ms 
                  Series      1000     int     skew    8.12ms 
                  Series      1000     int     kurt    8.28ms 
                  Series      1000     int     sum     7.89ms 
                  Series      1000     int     corr    91.4ms 
                  Series      1000     int     cov     57.8ms 
                  Series      1000    float   median   146ms  
                  Series      1000    float    mean    7.86ms 
                  Series      1000    float    max     9.57ms 
                  Series      1000    float    min     9.57ms 
                  Series      1000    float    std     9.67ms 
                  Series      1000    float   count    14.5ms 
                  Series      1000    float    skew    12.4ms 
                  Series      1000    float    kurt    12.7ms 
                  Series      1000    float    sum     7.59ms 
                  Series      1000    float    corr    85.8ms 
                  Series      1000    float    cov     56.5ms 
               ============ ======== ======= ======== ========

[100.00%] ··· Running rolling.Quantile.time_quantile                                                   ok
[100.00%] ···· 
               ============ ======== ======= ======= ======= =======
               --                                   percentile      
               ----------------------------- -----------------------
                contructor   window   dtype     0      0.5      1   
               ============ ======== ======= ======= ======= =======
                DataFrame      10      int    243ms   262ms   271ms 
                DataFrame      10     float   245ms   261ms   271ms 
                DataFrame     1000     int    400ms   496ms   455ms 
                DataFrame     1000    float   420ms   520ms   524ms 
                  Series       10      int    251ms   271ms   278ms 
                  Series       10     float   246ms   268ms   272ms 
                  Series      1000     int    363ms   454ms   458ms 
                  Series      1000    float   449ms   533ms   526ms 
               ============ ======== ======= ======= ======= =======
```
thanks!