-
-
Notifications
You must be signed in to change notification settings - Fork 17.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG: pd.Series.describe ignores include, exclude arguments #54193
Comments
Thanks for the report, but this is mentioned in the docstring in the notes section https://pandas.pydata.org/docs/reference/api/pandas.Series.describe.html
It probably would be more explicit to raise a |
Thanks for the answer But I'm sorry, I still don't get the point why it's mentioned only in the last line in Notes section. And why is there no opportunity to exclude some types for Series.describe? |
Well a Series has one data dtype, so |
Because of this commit in the numpy library - numpy/numpy@b3c0960 Maybe you should point it out in the documentation or perhaps return the |
Yeah either of these enhancements sounds good |
Frankly, the second option is preferable. To return |
Pandas version checks
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of pandas.
I have confirmed this bug exists on the main branch of pandas.
Reproducible Example
Issue Description
I explicitly exclude this type, but anyway, I get a description.
In the desribe.py module in the describe_ndframe function, I saw this code:
Which is the root cause of this bug.
If these arguments are ignored why they are mentioned in the documentation?
Expected Behavior
include and exclude arguments are not ignored
Installed Versions
INSTALLED VERSIONS
commit : 37ea63d
python : 3.9.6.final.0
python-bits : 64
OS : Darwin
OS-release : 22.3.0
Version : Darwin Kernel Version 22.3.0: Mon Jan 30 20:39:46 PST 2023; root:xnu-8792.81.3~2/RELEASE_ARM64_T6020
machine : arm64
processor : arm
byteorder : little
LC_ALL : en_US.UTF-8
LANG : en_US.UTF-8
LOCALE : en_US.UTF-8
pandas : 2.0.1
numpy : 1.24.2
pytz : 2023.3
dateutil : 2.8.2
setuptools : 65.5.1
pip : 23.1.2
Cython : None
pytest : None
hypothesis : None
sphinx : None
blosc : None
feather : None
xlsxwriter : None
lxml.etree : None
html5lib : None
pymysql : None
psycopg2 : None
jinja2 : 3.1.2
IPython : 8.12.0
pandas_datareader: None
bs4 : 4.12.2
bottleneck : None
brotli : None
fastparquet : None
fsspec : None
gcsfs : None
matplotlib : 3.7.1
numba : None
numexpr : None
odfpy : None
openpyxl : None
pandas_gbq : None
pyarrow : 12.0.0
pyreadstat : None
pyxlsb : None
s3fs : None
scipy : None
snappy : None
sqlalchemy : None
tables : None
tabulate : None
xarray : None
xlrd : None
zstandard : None
tzdata : 2023.3
qtpy : None
pyqt5 : None
The text was updated successfully, but these errors were encountered: