CategoricalAccessor.categorical removed in 0.24.0rc1 #24751
State: closed

- [ ] closes #24751 
- [ ] tests added / passed
- [ ] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry


Labels:
name: Categorical
description: Categorical Data Type
name: Deprecate
description: Functionality to remove in pandas

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

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

```diff
@@             Coverage Diff             @@
##           master   #24754       +/-   ##
===========================================
- Coverage   92.38%   42.91%   -49.47%     
===========================================
  Files         166      166               
  Lines       52363    52370        +7     
===========================================
- Hits        48376    22476    -25900     
- Misses       3987    29894    +25907
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `?` | |
| #single | `42.91% <55.55%> (-0.01%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24754?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/arrays/categorical.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvYXJyYXlzL2NhdGVnb3JpY2FsLnB5) | `41.43% <55.55%> (-54.5%)` | :arrow_down: |
| [pandas/io/formats/latex.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL2Zvcm1hdHMvbGF0ZXgucHk=) | `0% <0%> (-100%)` | :arrow_down: |
| [pandas/core/categorical.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvY2F0ZWdvcmljYWwucHk=) | `0% <0%> (-100%)` | :arrow_down: |
| [pandas/io/sas/sas\_constants.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL3Nhcy9zYXNfY29uc3RhbnRzLnB5) | `0% <0%> (-100%)` | :arrow_down: |
| [pandas/tseries/plotting.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL3RzZXJpZXMvcGxvdHRpbmcucHk=) | `0% <0%> (-100%)` | :arrow_down: |
| [pandas/tseries/converter.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL3RzZXJpZXMvY29udmVydGVyLnB5) | `0% <0%> (-100%)` | :arrow_down: |
| [pandas/io/formats/html.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL2Zvcm1hdHMvaHRtbC5weQ==) | `0% <0%> (-99.35%)` | :arrow_down: |
| [pandas/core/groupby/categorical.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZ3JvdXBieS9jYXRlZ29yaWNhbC5weQ==) | `0% <0%> (-95.46%)` | :arrow_down: |
| [pandas/io/sas/sas7bdat.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL3Nhcy9zYXM3YmRhdC5weQ==) | `0% <0%> (-91.17%)` | :arrow_down: |
| [pandas/io/sas/sas\_xport.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL3Nhcy9zYXNfeHBvcnQucHk=) | `0% <0%> (-90.15%)` | :arrow_down: |
| ... and [124 more](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree-more) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24754?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/24754?src=pr&el=footer). Last update [f160c7d...4bba94c](https://codecov.io/gh/pandas-dev/pandas/pull/24754?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/24754?src=pr&el=h1) Report
> Merging [#24754](https://codecov.io/gh/pandas-dev/pandas/pull/24754?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/0bd454cdc9307d3a7e73403c49cc8350965628ce?src=pr&el=desc) will **increase** coverage by `<.01%`.
> The diff coverage is `100%`.

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

```diff
@@            Coverage Diff             @@
##           master   #24754      +/-   ##
==========================================
+ Coverage   92.38%   92.38%   +<.01%     
==========================================
  Files         166      166              
  Lines       52366    52375       +9     
==========================================
+ Hits        48380    48389       +9     
  Misses       3986     3986
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.81% <100%> (ø)` | :arrow_up: |
| #single | `42.91% <46.15%> (-0.01%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24754?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/arrays/categorical.py](https://codecov.io/gh/pandas-dev/pandas/pull/24754/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvYXJyYXlzL2NhdGVnb3JpY2FsLnB5) | `95.97% <100%> (+0.04%)` | :arrow_up: |

------

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

Given @jreback's suggestion that this is unnecessary, I will close this.
You'll also need to update uses of `self.index` to `self._index` or `self._parent.index`. I didn't realize these were public on master. It's probably best make these private as well (as you've done), just have to make sure we don't use the deprecated version internally.
Hello @benjaminr! Thanks for updating the PR.









Cheers ! There are no PEP8 issues in this Pull Request. :beers: 

##### Comment last updated on January 15, 2019 at 20:23 Hours UTC
Just a comment.

On Tue, Jan 15, 2019 at 11:39 AM Benjamin Rowell <notifications@github.com>
wrote:

> *@benjaminr* commented on this pull request.
> ------------------------------
>
> In pandas/tests/series/test_api.py
> <https://github.com/pandas-dev/pandas/pull/24754#discussion_r247992646>:
>
> > @@ -245,10 +245,11 @@ def test_tab_completion(self):
>
>      def test_tab_completion_with_categorical(self):
>          # test the tab completion display
> -        ok_for_cat = ['categories', 'codes', 'ordered', 'set_categories',
>
> Ah no worries.
>
> When you say note on that property, is a comment sufficient, or do you
> mean in the deprecation FutureWarning message?
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <https://github.com/pandas-dev/pandas/pull/24754#discussion_r247992646>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/ABQHIgk_z0azVQ6WA6hqa68nOy2MQkBGks5vDhJBgaJpZM4Z9XZr>
> .
>

Thanks @benjaminr!