版本 0.19.2 (2016年12月24日)#

这是 0.19.x 系列的一个次要错误修复版本,包含了一些小的回归修复、错误修复和性能改进。我们建议所有用户升级到此版本。

亮点包括

增强功能#

在 0.19.0 中添加的 pd.merge_asof() 获得了一些改进

  • pd.merge_asof() 增加了 left_index/right_indexleft_by/right_by 参数 (GH 14253)

  • pd.merge_asof() 可以在 by 参数中接受多个列,并具有专门的 dtype 以获得更好的性能 (GH 13936)

性能改进#

  • PeriodIndex 性能回归 (GH 14822)

  • 使用 getitem 索引时出现性能回归 (GH 14930)

  • 改进了 .replace() 的性能 (GH 12745)

  • 改进了使用 datetime 索引和字典数据创建 Series 的性能 (GH 14894)

错误修复#

  • 兼容 python 3.6,用于某些 offset 的 pickling (GH 14685)

  • 兼容 python 3.6,用于某些索引异常类型 (GH 14684, GH 14689)

  • 兼容 python 3.6,用于测试套件中的弃用警告 (GH 14681)

  • 兼容 python 3.6,用于 Timestamp pickles (GH 14689)

  • 兼容 dateutil==2.6.0;测试套件中报告了段错误 (GH 14621)

  • 允许在 Timestamp.replace 中将 nanoseconds 作为 kwarg 使用 (GH 14621)

  • pd.read_csv 中的一个错误,当 na_values 以字典形式传递时,发生了别名处理 (GH 14203)

  • pd.read_csv 中的一个错误,类字典 na_values 的列索引未被遵守 (GH 14203)

  • pd.read_csv 中的一个错误,如果文件中的头行数等于总行数,则文件读取失败 (GH 14515)

  • pd.read_csv 的 Python 引擎中的一个错误,当多字符分隔符在引号内未被正确识别时,会抛出无用的错误消息 (GH 14582)

  • 修复了 pd.read_saspandas.io.sas.sas7bdat.SAS7BDATReader 中的错误 (GH 14734, GH 13654),这些错误导致在增量读取 SAS 文件时出现问题。

  • pd.read_csv 的 Python 引擎中的一个错误,当 Python 的 CSV 库不遵守 skipfooter 参数时,会抛出无用的错误消息 (GH 13879)

  • .fillna() 中的一个错误,时区感知的 datetime64 值被错误地舍入 (GH 14872)

  • 对非字典顺序的 MultiIndex 使用 .groupby(..., sort=True) 并按多个级别分组时出现错误 (GH 14776)

  • 使用负值和单个 bin 调用 pd.cut 时出现错误 (GH 14652)

  • 使用 pd.to_numeric 并指定 downcast='unsigned' 参数时,0 未被转换为无符号数 (GH 14401)

  • 使用共享轴(sharex=Trueax.twinx())绘制规则和不规则时间序列时出现错误 (GH 13341, GH 14322)。

  • 在解析无效 datetime 时未传播异常的错误,在 python 3.6 中发现 (GH 14561)

  • 在本地时区重采样 DatetimeIndex 并跨越 DST 变更时出现错误,这会导致抛出 AmbiguousTimeError (GH 14682)

  • 索引中的一个错误,将 RecursionError 转换为 KeyErrorIndexingError (GH 14554)

  • 使用 data_columns=True 写入 MultiIndex 时,HDFStore 中的一个错误 (GH 14435)

  • 在写入 Series 并传递包含 index 值的 min_itemsize 参数时,HDFStore.append() 中的一个错误 (GH 11412)

  • table 格式向 HDFStore 写入数据,并为 index 指定 min_itemsize 值且未要求追加时出现错误 (GH 10381)

  • 对于空的 SeriesSeries.groupby.nunique() 抛出 IndexError 的错误 (GH 12553)

  • 当索引具有重复值时,DataFrame.nlargestDataFrame.nsmallest 中的错误 (GH 13412)

  • linux 上 python2 中处理 unicode 和分隔符的剪贴板函数中的错误 (GH 13747)

  • Windows 10 和 python 3 中剪贴板函数中的错误 (GH 14362, GH 12807)

  • .to_clipboard() 和 Excel 兼容性错误 (GH 12529)

  • 整数列使用 DataFrame.combine_first() 时出现错误 (GH 14687)。

  • pd.read_csv() 中的一个错误,对于空数据,dtype 参数未被遵守 (GH 14712)

  • 使用 C 引擎解析大输入时,pd.read_csv() 中的一个错误,nrows 参数未被遵守 (GH 7626)

  • 指定 tolerance 时,pd.merge_asof() 无法处理时区感知的 DatetimeIndex 的错误 (GH 14844)

  • to_stataStataWriter 中写入双精度浮点数时,对超出范围的值进行显式检查 (GH 14618)

  • .plot(kind='kde') 中的一个错误,它没有丢弃缺失值来生成 KDE 图,而是生成了一个空图。 (GH 14821)

  • 如果使用列列表作为参数调用 unstack(),无论所有列的 dtype 如何,它们都会被强制转换为 object 的错误 (GH 11847)

贡献者#

共有 33 人为此版本贡献了补丁。姓名旁边带有“+”的人是首次贡献补丁。

  • Ajay Saxena +

  • Ben Kandel

  • Chris

  • Chris Ham +

  • Christopher C. Aycock

  • Daniel Himmelstein +

  • Dave Willmer +

  • Dr-Irv

  • Jeff Carey +

  • Jeff Reback

  • Joe Jevnik

  • Joris Van den Bossche

  • Julian Santander +

  • Kerby Shedden

  • Keshav Ramaswamy

  • Kevin Sheppard

  • Luca Scarabello +

  • Matt Roeschke +

  • Matti Picus +

  • Maximilian Roos

  • Mykola Golubyev +

  • Nate Yoder +

  • Nicholas Ver Halen +

  • Pawel Kordek

  • Pietro Battiston

  • Rodolfo Fernandez +

  • Tara Adiseshan +

  • Tom Augspurger

  • Yaroslav Halchenko

  • gfyoung

  • hesham.shabana@hotmail.com +

  • sinhrks

  • wandersoncferreira +