CLN: ASV categoricals benchmark
State: closed

- Split classes from `Categoricals/2/3` --> `Concat`, `ValueCounts`, `Rank`, `Repr`, `SetCategories`, and `Constructor`

- Utilized `params` and `param_names` for `ValueCounts`

- Added `np.random.seed(1234)` in setup classes where random data is created xref #8144

- Ran flake8 and replaced star imports

```
$ asv run -q -b ^categoricals
[  0.00%] ·· Benchmarking conda-py3.6-Cython-matplotlib-numexpr-numpy-openpyxl-pytables-pytest-scipy-sqlalchemy-xlrd-xlsxwriter-xlwt
[  5.88%] ··· Running categoricals.Concat.time_concat                                                                               14.2ms
[ 11.76%] ··· Running categoricals.Concat.time_union                                                                                12.2ms
[ 17.65%] ··· Running categoricals.Constructor.time_constructor_all_nan                                                             54.7ms
[ 23.53%] ··· Running categoricals.Constructor.time_constructor_datetimes                                                           2.22ms
[ 29.41%] ··· Running categoricals.Constructor.time_constructor_datetimes_with_nat                                                  2.32ms
[ 35.29%] ··· Running categoricals.Constructor.time_constructor_fastpath                                                            1.59ms
[ 41.18%] ··· Running categoricals.Constructor.time_constructor_regular                                                             48.8ms
[ 47.06%] ··· Running categoricals.Constructor.time_constructor_with_nan                                                             510ms
[ 52.94%] ··· Running categoricals.Rank.time_rank_int                                                                               11.7ms
[ 58.82%] ··· Running categoricals.Rank.time_rank_int_cat                                                                           12.9ms
[ 64.71%] ··· Running categoricals.Rank.time_rank_int_cat_ordered                                                                   12.2ms
[ 70.59%] ··· Running categoricals.Rank.time_rank_string                                                                             520ms
[ 76.47%] ··· Running categoricals.Rank.time_rank_string_cat                                                                        18.3ms
[ 82.35%] ··· Running categoricals.Rank.time_rank_string_cat_ordered                                                                10.2ms
[ 88.24%] ··· Running categoricals.Repr.time_rendering                                                                              1.58ms
[ 94.12%] ··· Running categoricals.SetCategories.time_set_categories                                                                70.7ms
[100.00%] ··· Running categoricals.ValueCounts.time_value_counts                                                                81.2ms;...
```

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

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

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

```diff
@@            Coverage Diff             @@
##           master   #18465      +/-   ##
==========================================
- Coverage   91.34%   91.32%   -0.02%     
==========================================
  Files         163      163              
  Lines       49717    49717              
==========================================
- Hits        45413    45404       -9     
- Misses       4304     4313       +9
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `89.12% <ø> (ø)` | :arrow_up: |
| #single | `40.51% <ø> (-0.07%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/18465?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/io/gbq.py](https://codecov.io/gh/pandas-dev/pandas/pull/18465?src=pr&el=tree#diff-cGFuZGFzL2lvL2dicS5weQ==) | `25% <0%> (-58.34%)` | :arrow_down: |
| [pandas/core/frame.py](https://codecov.io/gh/pandas-dev/pandas/pull/18465?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZnJhbWUucHk=) | `97.8% <0%> (-0.1%)` | :arrow_down: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18465?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/18465?src=pr&el=footer). Last update [412988e...3fcf30f](https://codecov.io/gh/pandas-dev/pandas/pull/18465?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

Kept the removed imports, changed the redundant method names, and changed `self.dropna` -> `dropna`
thanks!