Use of Standardizer to handle outliers?

I have a dataset with 60 columns and 5K records. There are few columns which has outliers. I understand that there are multiple approach to handle outliers.

Actually I don't wish to drop the data as it is an outlier because am not sure whether it is really an outlier or a meaningful value (like how income could be skewed).

So what I did is just standardize the columns using standard scaler.

Is it okay to do this? Am assuming that by doing this standard scaling, I have retained the data as well as got rid of outliers.

I did refer couple of posts (post1, post2) but couldn't get an idea

Is this what standardization does? Can anyone suggest me is there anyother way to handle outliers without dropping the records?

Can you help?

Standardising may not be the best option.

Because they will still not be bounded (like when normalised) between -1 and 1 but be distribution dependent. What I mean is if they are outliers their standard deviation will be big for these values. In any case its not that you should rescale the values to combat these outliers. Outliers are not in the first place problematic because they are big in values, but mostly because these values lie in the cluster thats not possible/representative of future data and you will learn on it.

One solution for without dropping them is for example binning, where you say all outliers that have standard deviation bigger than two should have value "X" where X is some 99,5% quantile for example.

• Thanks upvoted for your help. I would like to understand a bit about your suggestion on binning. Can you provide an example to help me understand. Let's say that I have values like 200,300,350,245,560,10000. Here 10000 is an outlier – The Great Dec 26 '19 at 10:17
• Whats standard devitation of your baby set (with or without 10 000) its 500 for example, 2 times this is 1000 s you would set all values that are bigger than 1000 to 1000 – Noah Weber Dec 26 '19 at 10:19
• got you. Anything above 2sd, should be set to the maximum value (within 2sd). got it. marked as answer – The Great Dec 26 '19 at 10:20

When you dont want to remove outlier then you can either use logistic regression if it is classification task as we know log reg is robust to outliers because of sigmoidal function. Otherwise for general you can use local reachability factor value to check whether you datapoint is having this factor value significantly different from other datapoints. Local reachability factor and remove these higher value datapoints from the dataset.

• thanks for the response. Upvoted. So, standardizing may not be the best option? – The Great Dec 26 '19 at 6:05

No, simply if you standardize you are taking outlier into consideration and if you are using sensitive model which gets affected with outlier like KNN etc then it is not good practice to do that. I suggest either choose distance unsensitive model or remove outliers then only your performance may increase.