Model.plot

In [ ]:
Model.plot(color: str = "#FE5016", 
           ax=None,
           **style_kwds,)

Draws the kernel density estimation of the model.

Parameters

Name Type Optional Description
color
str
The Plot color.
ax
Matplotlib axes object
The axes to plot on.
**style_kwds
any
Any optional parameter to pass to the Matplotlib functions.

Returns

ax : Matplotlib axes object

Example

In [2]:
# KDE
from verticapy.learn.neighbors import KernelDensity
model = KernelDensity(name = "public.KDE_iris", nbins = 40)
model.drop()
model.fit("public.iris", 
          ["PetalLengthCm", "PetalWidthCm"])
model.plot()
Out[2]:
<AxesSubplot:xlabel='"PetalLengthCm"', ylabel='"PetalWidthCm"'>