Last active
March 9, 2019 11:17
-
-
Save dvgodoy/c849b9324b044e772498768ad84c38fb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### CLEANING UP DATA | |
| ### IMPUTING MISSING VALUES | |
| # Fills missing values for Age, stratifying it by Pclass and Sex | |
| hdf_filled = hdf.stratify(['Pclass', 'Sex']).fill(continuous=['Age'], strategy=['mean']) | |
| ### HANDLING OUTLIERS | |
| # Fences outlier values for Fare | |
| hdf_fenced = hdf_filled.fence(['Fare'], k=3) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment