Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compute spacing/width separately for unshared axes #3119

Merged
merged 4 commits into from
Oct 30, 2022

Conversation

mwaskom
Copy link
Owner

@mwaskom mwaskom commented Oct 30, 2022

Motivating example (from #3112):

(
    sns.load_dataset("penguins")
    .melt(["species"], ["bill_depth_mm", "bill_length_mm"])
    .pipe(so.Plot, x="value", color="species")
    .facet("variable")
    .add(so.Bars(), so.Hist(common_bins=["col"]))
    .share(x=False)
)

Before:

After:

(This is a little artificial because you could just use Plot.pair here but there are other cases where you'd actually want faceting).

@codecov
Copy link

codecov bot commented Oct 30, 2022

Codecov Report

Merging #3119 (f9a4c96) into master (021a20f) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #3119   +/-   ##
=======================================
  Coverage   98.41%   98.41%           
=======================================
  Files          76       76           
  Lines       24056    24076   +20     
=======================================
+ Hits        23675    23695   +20     
  Misses        381      381           
Impacted Files Coverage Δ
seaborn/utils.py 95.46% <ø> (ø)
seaborn/_core/plot.py 99.33% <100.00%> (+<0.01%) ⬆️
tests/_core/test_plot.py 98.68% <100.00%> (+0.01%) ⬆️

@mwaskom mwaskom merged commit 8dc5a9c into master Oct 30, 2022
@mwaskom mwaskom deleted the fix/unshared_spacing branch October 30, 2022 17:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant