Skip to content

capability__categorical_in_X

capability__categorical_in_X

capability__categorical_in_X()[source]

Capability: the estimator can handle categorical variables in the X argument.

  • String name: "capability:categorical_in_X"

  • Public capability tag

  • Values: boolean, True / False

  • Example: True

  • Default: True

This tag applies to the X argument of forecasters (exogenous data), transformers, classifiers, and regressors.

A column of X is categorical if its feature_kind, as inferred by sktime.datatypes.check_is_scitype, is DtypeKind.CATEGORICAL. This is determined by the column dtype, e.g., for pandas inputs, dtypes object, string, category, and datetime-like are categorical, while numeric and boolean dtypes are not.

If the tag is True, X is passed to the estimator unchanged, and the estimator is expected to handle categorical columns natively.

If the tag is False, the estimator cannot handle categorical columns, and will raise a TypeError if X contains one. For forecasters, this applies only if capability:exogenous is True.