Polynomial Features

../../../../_images/polynomial.svg

Generate a new feature matrix consisting of all polynomial combinations of the features with less than a given degree

Documentation

Generate a new feature matrix consisting of all polynomial combinations of the features with less than a given degree

Configuration:

  • degree

    The degree of the polynomial features.

  • interaction_only

    If true, only interaction features are produced: features that are products of at most degree distinct input features (so not x ** 2, x * x ** 3, etc.).

  • include_bias

    If True (default), then include a bias column, the feature in which all polynomial powers are zero (i.e. a column of ones - acts as an intercept term in a linear model).

Attributes:

  • n_input_features_

  • n_output_features_

  • powers_

Input ports:

Output ports:
modelmodel

Model

Definition

Input ports

Output ports

model

model

Model

class node_preprocessing.PolynomialFeatures[source]