describe() returns RuntimeWarning: Invalid value encountered in median RuntimeWarning #13146
Labels
Bug
Duplicate Report
Duplicate issue or pull request
Numeric Operations
Arithmetic, Comparison, and Logical operations
I just upgraded to 18.1 w/ conda. I started noticing this problem in some notebooks I created before the upgrade but recently revisited for further analysis.
Code Sample, a copy-pastable example if possible
df.value.describe()
returns a RuntimeWarning from numpy, which then gives this unexpected result for the quantiles:Expected Output
I got this using a different conda environment that has not been upgraded to latest pandas version:
Dropping the NaN's works in pandas 18.1:
However, this work-around is not a great option when multiple columns w/ NaNs are present:
output of
pd.show_versions()
INSTALLED VERSIONS
commit: None
python: 3.4.4.final.0
python-bits: 64
OS: Darwin
OS-release: 15.4.0
machine: x86_64
processor: i386
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8
pandas: 0.18.1
nose: 1.3.7
pip: 8.1.1
setuptools: 20.2.2
Cython: 0.22.1
numpy: 1.10.4
scipy: 0.17.0
statsmodels: 0.6.1
xarray: None
IPython: 4.2.0
sphinx: 1.3.1
patsy: 0.3.0
dateutil: 2.4.2
pytz: 2015.7
blosc: None
bottleneck: 1.0.0
tables: 3.2.0
numexpr: 2.5
matplotlib: 1.5.1
openpyxl: 1.8.5
xlrd: 0.9.3
xlwt: 1.0.0
xlsxwriter: 0.7.3
lxml: 3.4.4
bs4: 4.3.2
html5lib: None
httplib2: 0.9.1
apiclient: None
sqlalchemy: 1.0.5
pymysql: None
psycopg2: None
jinja2: 2.8
boto: 2.38.0
pandas_datareader: None
The text was updated successfully, but these errors were encountered: