Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

pandas how to drop rows with extreme values in a single column

standard_deviations = 3
new_df = df[((df['col'] - df['col'].mean()) / df['col'].std()).abs() < standard_deviations]
Comment

PREVIOUS NEXT
Code Example
Python :: delete element from matrix python 
Python :: python max value in list 
Python :: head first python by paul barry pdf 
Python :: factorial program in python 
Python :: Flatten List in Python Using NumPy flat 
Python :: requirement.txt for python 
Python :: lucky number codechef solution 
Python :: from_bytes python 
Python :: stop flask server 
Python :: django background_task 
Python :: django form formatting 
Python :: hyperparameters 
Python :: tuple count in python 
Python :: how to combine two lists in python 
Python :: moving element to last position in a list python 
Python :: how to get the number of rows and columns in a numpy array 
Python :: how to merge dictionaries in python 
Python :: download python libraries offline 
Python :: how to use list in python 
Python :: pop element from heap python 
Python :: How do I plot a csv file in Jupyter notebook? 
Python :: call matlab function from python 
Python :: python tuple 
Python :: python string to list of chars 
Python :: can a function output be save as a variable python 
Python :: bot delete embed py 
Python :: current page django 
Python :: filter query objects by date range in Django 
Python :: find common string in two strings python 
Python :: python rock paper scissors game 
ADD CONTENT
Topic
Content
Source link
Name
5+3 =