Feature generation
Construction of new features from existing ones
CreatePolynomialFeatures
CreatePolynomialFeatures(self, inputs, *, degree=2)
A step for generating polynomial features.
Parameters
Name | Type | Description | Default |
---|---|---|---|
inputs |
SelectionType | A selection of columns to generate polynomial features. All columns must be numeric. | required |
degree |
int | The maximum degree of polynomial features to generate. | 2 |
Examples
>>> import ibis_ml as ml
Generate polynomial features for all numeric columns with a degree is 2.
>>> step = ml.CreatePolynomialFeatures(ml.numeric(), degree=2)
Generate polynomial features a specific set of columns.
>>> step = ml.CreatePolynomialFeatures(["x", "y"], degree=2)