Closed laurentiush closed 11 months ago
The following example taken from the documentation fails:
df = pd.DataFrame({ 'col1': np.arange(11), 'col2': np.arange(11) }) (ggplot(df, aes('col1', 'np.square(col2)', color='col2')) + geom_point(size=3) )
with the following error:
TypeError: cmap_pal.__init__() takes 2 positional arguments but 3 were given
see https://plotnine.readthedocs.io/en/stable/generated/plotnine.mapping.aes.html#plotnine.mapping.aes for the example.
Make sure plotnine and mizani packages have compatible versions.
plotnine
mizani
pip install "plotnine==0.12.2" pip install "mizani<0.10.0"
The following example taken from the documentation fails:
with the following error:
TypeError: cmap_pal.__init__() takes 2 positional arguments but 3 were given
see https://plotnine.readthedocs.io/en/stable/generated/plotnine.mapping.aes.html#plotnine.mapping.aes for the example.