任何人都可以搞清楚吗?或者一些猜测?非常感谢!
我想你可以查看NA type promotions:
When introducing NAs into an existing SerIEs or DataFrame via reindex or some other means,boolean and integer types will be promoted to a different dtype in order to store the NAs. These are summarized by this table:
Typeclass Promotion dtype for storing NAsfloating no changeobject no changeinteger cast to float64boolean cast to object
总结While this may seem like a heavy Trade-off,in practice I have found very few cases where this is an issue in practice. Some explanation for the motivation here in the next section.
以上是内存溢出为你收集整理的python – Pandas读取sql整数变为浮点数全部内容,希望文章能够帮你解决python – Pandas读取sql整数变为浮点数所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)