Exploratory Data Analysis Cheat Sheet
A systematic workflow for exploring a new dataset, covering summary statistics, distribution plots, correlation analysis, and visualization with pandas and seaborn.
1 PageBeginnerMar 15, 2026
First Look at the Data
Shape, types, and summary statistics.
python
import pandas as pddf = pd.read_csv("data.csv")df.shape # (rows, columns)df.info() # dtypes, non-null counts, memory usagedf.describe() # count, mean, std, min, quartiles, max for numeric colsdf.describe(include="object") # summary for categorical columnsdf.head()df.isnull().sum()df.nunique() # unique value counts per columndf["category"].value_counts(normalize=True) # class proportions
Visualizing the Data
Distributions, boxplots, and correlations.
python
import seaborn as snsimport matplotlib.pyplot as plt# Distribution of a numeric variablesns.histplot(df["income"], kde=True, bins=30)# Boxplot to spot outliers/spread by categorysns.boxplot(x="category", y="income", data=df)# Correlation heatmapcorr = df.corr(numeric_only=True)sns.heatmap(corr, annot=True, cmap="coolwarm", center=0)# Pairwise relationships between numeric featuressns.pairplot(df, hue="target", vars=["age", "income", "score"])plt.tight_layout()plt.show()
EDA Checklist
A systematic order for exploring a new dataset.
- Shape & dtypes- confirm row/column counts and correct data types before anything else
- Summary statistics- mean, median, std, min/max reveal scale and possible errors
- Missing data pattern- check whether missingness is random or correlated with other features
- Distribution shape- check skewness, multi-modality, and outliers with histograms/KDE
- Correlation analysis- look for multicollinearity and target-feature relationships
- Class balance- check the target variable distribution for classification tasks
- Categorical cardinality- count unique values per categorical column to plan encoding
- Bivariate analysis- explore relationships between pairs of features (scatter, boxplot, groupby)
Useful Pandas Methods
Quick lookups for common EDA operations.
- df.groupby(col).agg()- compute grouped summary statistics
- df.corr()- pairwise correlation matrix of numeric columns
- df.value_counts()- frequency count of unique values in a Series
- df.sample(n)- random subset of rows for a quick sanity check
- df.select_dtypes()- filter columns by data type (e.g. include=['number'])
- pd.crosstab()- cross-tabulation frequency table between two categorical columns
Pro Tip
Always plot the target variable's distribution first — a skewed regression target (e.g. housing prices) often benefits from a log transform, and a heavily imbalanced classification target changes which metrics and resampling strategies you should use downstream.
Was this cheat sheet helpful?
Explore Topics
#ExploratoryDataAnalysis#ExploratoryDataAnalysisCheatSheet#DataScience#Beginner#FirstLookAtTheData#VisualizingTheData#EDAChecklist#UsefulPandasMethods#MachineLearning#CheatSheet#SkillVeris
Advertisement
Sri Hayavadhana Info-Tech
Professional Web Designing Services
- Responsive Websites
- E-commerce Solutions
- SEO Friendly Design
- Fast & Secure
- Support & Maintenance