Skip to content

Overlapping labels in relplot with seaborn 0.12 #3179

@sorenwacker

Description

@sorenwacker
import seaborn as sns

sns.set_context("paper")
sns.set_style("white")

data = (sns.load_dataset('iris').set_index('species')*1e7).reset_index()
g = sns.relplot(data=data, x='sepal_length', y='sepal_width', col='species', 
                col_wrap=2, height=2.5)
g.set_titles(row_template="{row_name}", col_template="SOMEWHATLONG-{col_name}")
for axes in g.axes.flat:
    axes.ticklabel_format(axis='both', style='scientific', scilimits=(0, 0))
import seaborn as sns

sns.set_context("paper")
sns.set_style("white")

data = (sns.load_dataset('iris').set_index('species')*1e7).reset_index()
g = sns.relplot(data=data, x='sepal_length', y='sepal_width', col='species', 
                col_wrap=2, height=2.5, facet_kws=dict(sharex=False, sharey=False))
g.set_titles(row_template="{row_name}", col_template="SOMEWHATLONG-{col_name}")
for axes in g.axes.flat:
    axes.ticklabel_format(axis='both', style='scientific', scilimits=(0, 0))

seaborn 11.2:

image
image

seaborn 12.1:

image
imagey

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions