July 2016
Beginner to intermediate
462 pages
9h 14m
English
Winsorizing is another technique to deal with outliers and is named after Charles Winsor. In effect, Winsorization clips outliers to given percentiles in a symmetric fashion. For instance, we can clip to the 5th and 95th percentile. SciPy has a winsorize() function, which performs this procedure. The data for this recipe is the same as that for the Clipping and filtering outliers recipe.
Winsorize the data with the following procedure:
rom scipy.stats.mstats import winsorize import statsmodels.api as sm import seaborn as sns import matplotlib.pyplot as plt import dautil as dl from IPython.display import HTML