Column preprocessors
class Categorical
Categorical.__init__
def __init__( base: int = 1024, special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Categorical column preprocessor treating categories as ordinal values.
Arguments:
base
- The base in which to represent the ordinal values associated to the categories.special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class Coordinates
Coordinates.__init__
def __init__( base: int = 10, digits: int = 10, special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Coordinate column preprocessor.
Arguments:
base
- Base in which to represent the coordinate values.digits
- Number of digits to keep in the coordinate values.special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class Date
Date.__init__
def __init__( fmt: str | None = None, special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Date column preprocessor respecting a weekly periodicity.
Arguments:
fmt
- Datetime format. If None, it will be automatically inferred.special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class Time
Time.__init__
def __init__( fmt: str | None = None, special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Time column preprocessor.
Arguments:
fmt
- Timetime format. If None, it will be automatically inferred.special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class Datetime
Datetime.__init__
def __init__( date: Date | None = None, time: Time | None = None, fmt: str | None = None, special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Datetime column preprocessor.
Arguments:
date
- ADate
preprocessor or None. If None, the defaultDate
object is used.time
- ATime
preprocessor or None. If None, the defaultTime
object is used.fmt
- Datetime format. If None, it will be automatically inferred.special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class Integer
Integer.__init__
def __init__( base: int = 10, special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Integer column preprocessor.
Arguments:
base
- Base in which to represent the integer values.special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class ItaFiscalCode
ItaFiscalCode.__init__
def __init__( special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Column preprocessor for Italian Fiscal Code.
Arguments:
special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class Numeric
Numeric.__init__
def __init__( base: int = 10, max_digits: int = 12, special_values: Sequence = (), impute_nan: bool = False, non_sample_values: Sequence = (), protection: Protection = Protection()) -> None
Numeric column preprocessor.
Arguments:
base
- The base of the numeric system.max_digits
- Number of digits to keep in the numeric values.special_values
- A sequence of values to be handled separately as categories.impute_nan
- Whether to impute NaN values. If True, NaN values are replaced with other plausible values.non_sample_values
- A sequence of values that should not be sampled.protection
- AProtection
object.
class Text
Text column preprocessor.