How to eliminate out outliers in a dataframe

0 votes
I want to find and replace outliers - values greater than (mean+/-2 STd) with mean
Jul 24, 2019 in Python by Lohit
961 views

1 answer to this question.

0 votes
There are various ways we can replace the outliers it depends on the type of data you have, suppose you have some data with one of the columns has values 1,2,3,6,3,2,4,987 Now if you see most of the values are very much close to each other but there is one value which is too large in this case we use standard scaler or min-max scaler to normalize it since for this column range is very high, you can also replace the outliers by applying a condition if value is greater than the mean value of the column then replace it by mean value but standard scaler recommend when your data size is very big,
answered Jul 24, 2019 by Shri

Related Questions In Python

–1 vote
2 answers
0 votes
1 answer

How to find if a value exists in Pandas dataframe?

Try this:​ for name in df['Name']: ...READ MORE

answered Apr 8, 2019 in Python by Tina
13,061 views
0 votes
1 answer
0 votes
1 answer

How to iterate over row in a Dataframe in Pandas?

Hi, You can use df.iterrows(), it yields both ...READ MORE

answered Jul 19, 2019 in Python by Taj
• 1,080 points
3,382 views
0 votes
2 answers