Overview of the `preprocessing` module
masterThe preprocessing module in causallib provides specialized filters and transformers designed to augment scikit-learn. These tools are particularly useful for causal inference workflows where handling missing values (NaNs) and feature selection based on outcome association are critical.
Available Filters
Filters in this module remove features based on several criteria:
- Almost constant features: Removes features that are nearly constant in value (rather than just variance).
- Highly correlated features: Removes features that show high correlation with other features.
- Low variance features: Removes features with low variance (supports datasets containing
NaNvalues). - Mostly NaN features: Removes features that consist primarily of missing values.
- Outcome-associated features: Removes features that have a high association with the outcome (beyond simple correlation).
Available Transformers
- Standard Scaler: A scaler that handles
NaNvalues. - Min/Max Scaler: A standard min-max scaling transformer.
Note: A transformer to convert numpy arrays to pandas is planned for future releases.