是否不再支持通过 plotnine 的 ggplot2 for python?



尽管我得到了一个正确的图表(是的!(,但每次运行ggplot时我也会收到以下警告:

FutureWarning: Attribute 'is_copy' is deprecated and will be removed in a future version.return object.__setattr__(self, name, value)

我使用 Python 3.6 和:

from plotnine import * #Vers. 0.3.0
import pandas as pd #Vers. 0.23.1
from pandas import DataFrame

ggplot代码是:

g = ggplot(df, aes(x='date', y='meanDN')) + geom_point()
print(g)

我应该被承认吗?

警告来自对熊猫库的调用。 Plotnine仍然使用Pandas的功能,该功能已被弃用,并将在未来的版本中删除。

Plotnine正在积极开发中,并且已经修复了此错误。

在 plotnine 0.3.0 之后还没有新版本,因此您必须从 GitHub 安装开发版本或等待新版本以使警告消失。

最新更新