Model.fit¶
In [ ]:
Model.fit(input_relation: (str, vDataFrame),
X: list = [])
Trains the model.
Parameters¶
| Name | Type | Optional | Description |
|---|---|---|---|
input_relation | str | ❌ | Training relation. |
X | list | ✓ | List of the predictors. If empty, all the numerical vcolumns will be used. |
In [70]:
from verticapy.learn.cluster import KMeans
model = KMeans(name = "public.KMeans_iris",
n_cluster = 3)
model.fit("public.iris",
["PetalLengthCm", "PetalWidthCm"])
Out[70]:
