Using JointGrid and jointplot

Intermediate Data Visualization with Seaborn

Chris Moffitt

Instructor

JointGrid() Overview

JointGrid Overview

Intermediate Data Visualization with Seaborn

Basic JointGrid

g = sns.JointGrid(data=df, x="Tuition", y="ADM_RATE_ALL") 
g.plot(sns.regplot, sns.histplot)

JointGrid Example

Intermediate Data Visualization with Seaborn

Advanced JointGrid

g = sns.JointGrid(data=df, x="Tuition", y="ADM_RATE_ALL") 
g = g.plot_joint(sns.kdeplot)
g = g.plot_marginals(sns.kdeplot, shade=True)

JointGrid example annotated

Intermediate Data Visualization with Seaborn

jointplot()

sns.jointplot(data=df, x="Tuition", y="ADM_RATE_ALL", kind='hex')

jointplot example

Intermediate Data Visualization with Seaborn

Customizing a jointplot

g = (sns.jointplot(x="Tuition",
                   y="ADM_RATE_ALL",
                   kind="scatter",
                   xlim=(0, 25000),
                   data=df.query('UG < 2500 &
                   Ownership == "Public"'))
    .plot_joint(sns.kdeplot))
Intermediate Data Visualization with Seaborn

Customizing a jointplot

jointplot

Intermediate Data Visualization with Seaborn

Let's practice!

Intermediate Data Visualization with Seaborn

Preparing Video For Download...