Skip to contents

Relational plots

Visualize statistical relationships between numeric variables.

scatterplot()
Draw a scatter plot with semantic mappings
lineplot()
Draw a line plot with aggregation and error bands
relplot()
Figure-level interface for relational plots

Distribution plots

Visualize univariate and bivariate distributions.

histplot()
Plot a univariate or bivariate histogram
kdeplot()
Plot a univariate or bivariate kernel density estimate
ecdfplot()
Plot an empirical cumulative distribution function
rugplot()
Plot marginal rug ticks
displot()
Figure-level interface for distribution plots

Categorical plots

Visualize one numeric and one (or more) categorical variables.

boxplot()
Draw a box plot
violinplot()
Draw a violin plot
boxenplot()
Draw an enhanced box plot for larger datasets
stripplot()
Draw a categorical scatter with jitter
swarmplot()
Draw a categorical scatter with non-overlapping points
barplot()
Show point estimates and errors as bars
pointplot()
Show point estimates and errors with markers
countplot()
Show value counts as bars
catplot()
Figure-level interface for categorical plots

Regression plots

Visualize linear and other model fits with bootstrap confidence bands.

regplot()
Plot data and a linear regression model fit
residplot()
Plot the residuals of a linear regression
lmplot()
Figure-level interface for regression plots

Matrix plots

Visualize matrices as color-encoded heatmaps and clustered maps.

heatmap()
Plot rectangular data as a color-encoded matrix
clustermap()
Plot a hierarchically-clustered heatmap

Multi-plot grids

Compose grids of plots for pairwise and joint relationships.

pairplot()
Plot pairwise relationships in a dataset
jointplot()
Draw a bivariate plot with marginal distributions
FacetGrid()
A faceted grid of plots

Color palettes

Build and use seaborn’s color palettes (matched to the hex digit).

color_palette() hls_palette() husl_palette() dark_palette() light_palette() diverging_palette() blend_palette() mpl_palette() cubehelix_palette()
Return a list of colors or a continuous colormap defining a palette
set_color_codes()
Change how single-letter color codes are interpreted

Themes & contexts

Control the seaborn look — styles, scaling contexts, and despining.

set_theme() set()
Set multiple theme parameters in one step
axes_style() set_style()
Get the parameters that control the general style of the plots
plotting_context() set_context()
Get the parameters that control the scaling of plot elements
theme_seaborn()
Build a ggplot2 theme replicating a seaborn style + context
despine()
Remove spines from a plot
move_legend()
Reposition a plot's legend
reset_defaults() reset_orig()
Restore matplotlib/ggplot2 defaults
set_palette()
Set the matplotlib color cycle / ggplot default discrete palette

Datasets & utilities

Load example datasets and manipulate colors.

load_dataset() get_dataset_names()
Load an example dataset from the seaborn-data repository
desaturate()
Decrease the saturation of a color
saturate()
Increase the saturation of a color to its maximum
set_hls_values()
Independently set the hue, lightness, and/or saturation of a color
palplot()
Plot the values in a color palette as a horizontal array
dogplot()
Who's a good boy?

Python compatibility

Helpers that let pasted seaborn Python run unchanged.