Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

pandas removing outliers from dataframe

df[(df["col"] >= x ) & (df["col"] <= y )]

but it's more readable to use:

df[df["col"].between(x,y)]
Source by app.dataquest.io #
 
PREVIOUS NEXT
Tagged: #pandas #removing #outliers #dataframe
ADD COMMENT
Topic
Name
2+6 =