Code Sample, a copy-pastable example if possible

# Your code here
import pandas as pd
from pandas import DataFrame,Series
ages = [20,22,25,27,21,23,37,31,61,45,41,32]
bins = [18,25,35,60,100]
group_names = ['Youth','YoungAdult','MiddleAged','Senior']
pd.cut(ages,bins,labels=group_names)

cuts.labels
/Users/****/anaconda/bin/ipython:1: FutureWarning: 'labels' is deprecated. Use 'codes' instead
  #!/Users/****/anaconda/bin/python
Out[134]: array([3, 3, 3, 2, 3, 3, 0, 2, 1, 0, 0, 2], dtype=int8)

In [135]: cuts.codes
Out[135]: array([3, 3, 3, 2, 3, 3, 0, 2, 1, 0, 0, 2], dtype=int8)

Problem description

pd.cut() support argument labels not codes but the getter of the property support codes not labels

Expected Output

Output of pd.show_versions()

[paste the output of ``pd.show_versions()`` here below this line] In [137]: pd.show_versions() INSTALLED VERSIONS ------------------ commit: None python: 3.6.1.final.0 python-bits: 64 OS: Darwin OS-release: 16.7.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: None LANG: zh_CN.UTF-8 LOCALE: zh_CN.UTF-8 pandas: 0.20.1 pytest: 3.0.7 pip: 9.0.1 setuptools: 27.2.0 Cython: 0.25.2 numpy: 1.12.1 scipy: 0.19.0 xarray: None IPython: 5.3.0 sphinx: 1.5.6 patsy: 0.4.1 dateutil: 2.6.0 pytz: 2017.2 blosc: None bottleneck: 1.2.1 tables: 3.3.0 numexpr: 2.6.2 feather: None matplotlib: 2.0.2 openpyxl: 2.4.7 xlrd: 1.0.0 xlwt: 1.2.0 xlsxwriter: 0.9.6 lxml: 3.7.3 bs4: 4.6.0 html5lib: 0.999 sqlalchemy: 1.1.9 pymysql: None psycopg2: None jinja2: 2.9.6 s3fs: None pandas_gbq: None pandas_datareader: None

Comment From: jreback

this is as expected. pd.cut returns a categorical where the spelling for 'labels' is called categories. .labels is deprecated on a Categorical. Historically this argument has been named labels in the cut/qcut. I suppose we could accept cateogories as well (or maybe just deprecate labels, only +0 on this.

@TomAugspurger @chris-b1

Comment From: HinataHinata

I understand. but it is still a little bit werid. I think the setter and the getter is the same is better. perhaps support both 'labels' and 'cateogories' is better.

Comment From: jorisvandenbossche

I am not sure it is worth to deprecate it here. Note that 'labels' in some sense is still correct, because you do not specify the actual categories for the input data (as this are the bins), but the 'labels' for the resulting categories .. (of course how to interprete it is a bit subjective, but for me that is another reason I don't see the need to deprecate the labels kwarg).

Comment From: TomAugspurger

Agreed w/ not deprecating.

Comment From: jreback

closing as usage question.

@HinataHinata I think this is pretty clear from the doc-string, but as always if it is not, then a PR to make it better would be great.