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

obs. vs. obs for all grouped plots using BasePlot #2769

Open
wants to merge 28 commits into
base: main
Choose a base branch
from

Conversation

yugeji
Copy link

@yugeji yugeji commented Nov 28, 2023

  • Closes #1876 and reimplements stale PR #2055 zhangguy:dotplot2d
  • Empty group currently breaks
  • dendrogram doesn't work with all plots
  • I don't think anything would break if you just removed var_name reordering from the dendrogram entirely
  • add tests using groupby_cols params
  • Docs!

Copy link

codecov bot commented Nov 28, 2023

Codecov Report

Attention: Patch coverage is 54.23729% with 27 lines in your changes are missing coverage. Please review.

Project coverage is 75.12%. Comparing base (6542113) to head (1c4740e).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2769      +/-   ##
==========================================
- Coverage   75.24%   75.12%   -0.13%     
==========================================
  Files         116      116              
  Lines       12802    12847      +45     
==========================================
+ Hits         9633     9651      +18     
- Misses       3169     3196      +27     
Files Coverage Δ
scanpy/plotting/_anndata.py 84.98% <100.00%> (ø)
scanpy/plotting/_docs.py 100.00% <ø> (ø)
scanpy/plotting/_tools/__init__.py 77.28% <ø> (ø)
scanpy/testing/_helpers/__init__.py 100.00% <100.00%> (ø)
scanpy/plotting/_matrixplot.py 95.69% <66.66%> (-1.01%) ⬇️
scanpy/plotting/_dotplot.py 91.28% <71.42%> (-0.61%) ⬇️
scanpy/plotting/_stacked_violin.py 81.48% <62.50%> (-3.02%) ⬇️
scanpy/plotting/_baseplot_class.py 86.47% <34.78%> (-3.42%) ⬇️

@ivirshup ivirshup self-requested a review January 11, 2024 15:35
@flying-sheep flying-sheep requested review from flying-sheep and removed request for ivirshup February 22, 2024 15:37
@flying-sheep flying-sheep added this to the 1.11.0 milestone Mar 18, 2024
Comment on lines +478 to +483
# _matrix.columns = [f"{x}_{idx}" for idx, x in enumerate(_matrix.columns)] # added warning as this row was commented out
if _matrix.columns.value_counts().max() > 1:
warn(
"Duplicate gene or condition labels present."
"Results might be unexpected."
)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yugeji commenting this out doesn’t work with newer pandas versions anymore. Does your branch handle duplicated columns? Then we can just move this into the if len(self.groupby_cols) < 1: branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants