-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
dtype change when doing operations on dataframes #32822
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
dtype change when doing operations on dataframes #32822
Comments
This is because
When DataFrames contain only one column, Function |
I have few more observations. Series uses |
This looks to work on master now. Could use a test
|
I can fix it, can I make a pull request? |
Sure go for it @daksh-intwala |
It works fine on 1.2.4 version |
is issue still pending @mroeschke ? I can see that in the newer version we are not seeing this issue |
We would need a unit test (or confirmation of an existing/similar one) to close out this issue to prevent regressions. |
take |
Code Sample
Problem description
The Int64 dtype is changed when doing operations on two dataframes whereas it is kept (expected behavior) on series operations.
Expected Output
Output of
pd.show_versions()
INSTALLED VERSIONS
commit : None
python : 3.7.4.final.0
python-bits : 64
OS : Darwin
OS-release : 18.7.0
machine : x86_64
processor : i386
byteorder : little
LC_ALL : None
LANG : en_GB.UTF-8
LOCALE : en_GB.UTF-8
pandas : 1.0.3
numpy : 1.18.2
pytz : 2019.3
dateutil : 2.8.1
pip : 20.0.2
setuptools : 46.0.0
Cython : None
pytest : 5.4.1
hypothesis : None
sphinx : None
blosc : None
feather : None
xlsxwriter : None
lxml.etree : None
html5lib : None
pymysql : None
psycopg2 : None
jinja2 : 2.11.1
IPython : 7.13.0
pandas_datareader: None
bs4 : None
bottleneck : None
fastparquet : None
gcsfs : None
lxml.etree : None
matplotlib : None
numexpr : None
odfpy : None
openpyxl : None
pandas_gbq : None
pyarrow : 0.16.0
pytables : None
pytest : 5.4.1
pyxlsb : None
s3fs : 0.4.0
scipy : None
sqlalchemy : None
tables : None
tabulate : 0.8.6
xarray : None
xlrd : None
xlwt : None
xlsxwriter : None
numba : None
The text was updated successfully, but these errors were encountered: