Comments (2)
I like the name "Skrubber"
from skrub.
some examples of the kind of cleaning the tablevectorizer does:
>>> import pandas as pd
>>> from skrub import TableVectorizer
>>> skrubber = TableVectorizer(
... high_cardinality_transformer="passthrough",
... low_cardinality_transformer="passthrough",
... datetime_transformer="passthrough",
... numeric_transformer="passthrough",
... specific_transformers=(),
... )
>>> df = pd.DataFrame({
... 'a': ['2020-01-02', '2020-01-03'],
... 'b': ['2.2', 'nan'],
... 'c': [1.5, pd.NA],
... 'd': [True, False],
... 'e': pd.Series([4.5, 'a'], dtype='category'),
... })
>>> df
a b c d e
0 2020-01-02 2.2 1.5 True 4.5
1 2020-01-03 nan <NA> False a
>>> df.dtypes
a object
b object
c object
d bool
e category
dtype: object
>>> df['e'].cat.categories
Index([4.5, 'a'], dtype='object')
>>> skrubbed = skrubber.fit_transform(df)
>>> skrubbed
a b c d e
0 2020-01-02 2.2 1.5 1.0 4.5
1 2020-01-03 NaN NaN 0.0 a
>>> skrubbed.dtypes
a datetime64[ns]
b float32
c float32
d float32
e category
dtype: object
>>> skrubbed['e'].cat.categories
Index(['4.5', 'a'], dtype='object')
from skrub.
Related Issues (20)
- Add features to the `DatetimeEncoder` HOT 16
- Hacky Idea: ifelse in a pipeline HOT 10
- Scikit-learn v1.5 breaks skrub HOT 4
- `drop_nulls` and `is_null` have a different behavior for polars and pandas HOT 1
- Follow-ups after #902
- GapEncoder and MinHashEncoder modify their input inplace HOT 2
- adding `make_learner` to create a default pipeline for a given predictor
- AggJoiner raises exceptions when trying to join multiple tables at once HOT 5
- Faster alternative to GapEncoder HOT 1
- Display columns with the HTML representation of the fitted TableVectorizer
- `fetch_ken_embeddings` does not use `suffix` with default parameter HOT 1
- Ken embeddings RAM and disk usage HOT 2
- `SingleColumnTransformer`s don't work with `ColumnTransformer` HOT 4
- Port from sckikit-learn the positioning of the example buttons on downloading, jupyter-lite...
- Jupyter-lite picks up old versions of the examples? HOT 3
- Thebe + jupyterlite on the landing page
- Regroup developer docs in the main sphinx documentation
- Add a "DropSimilar" transformer
- Example 08_join_aggregation broken HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from skrub.