Data Science, Data Visualization, Analytics, Data Engineering, Data Analysis.
Q3 + 1.5 * IQR are potential outliers. Q1 = df['Column_Name'].quantile(0.25) Q3 = df['Column_Name'].quantile(0.75) IQR = Q3 - Q1 outliers = df[(df['Column_Name'] < (Q1 - 1.5 * IQR)) | (df['Column_Name'] > (Q3 + 1.5 * IQR))] Once you’ve identified outliers, you can decide whether to remove them, cap