Skip to main content

Tools to extend sklearn

Project description

sktools

https://img.shields.io/pypi/v/sktools.svg https://img.shields.io/travis/david26694/sktools.svg Documentation Status

Tools to extend sklearn

Usage

from sktools import IsEmptyExtractor

from sklearn.linear_model import LogisticRegression
from sklearn.pipeline import Pipeline

...

mod = Pipeline([
    ("impute-features", IsEmptyExtractor),
    ("model", LogisticRegression())
])

...

Features

Here’s a list of features that sktools currently offers:

  • sktools.encoders.NestedTargetEncoder performs target encoding suited for variables with nesting.

  • sktools.encoders.PercentileEncoder performs target aggregation using a quantile instead of the mean.

  • sktools.impute.IsEmptyExtractor creates binary variables indicating if there are missing values.

  • sktools.matrix_denser.MatrixDenser transformer that converts sparse matrices to dense.

  • sktools.quantilegroups.GroupedQuantileTransformer creates quantiles of a feature by group.

  • sktools.quantilegroups.PercentileGroupFeaturizer creates features regarding how an instance compares with a quantile of its group.

  • sktools.quantilegroups.MeanGroupFeaturizer creates features regarding how an instance compares with the mean of its group.

  • sktools.selectors.TypeSelector gets variables matching a type.

  • sktools.selectors.ItemsSelector allows to manually choose some variables.

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.

History

0.1.0 (2020-04-19)

  • First release on PyPI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sktools-0.1.1.tar.gz (26.6 kB view hashes)

Uploaded Source

Built Distribution

sktools-0.1.1-py2.py3-none-any.whl (14.7 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page