Skip to content

Fix dotplot vcenter=0 ignored due to falsy check#295

Open
PauBadiaM wants to merge 1 commit intomainfrom
fix/dotplot-vcenter-zero
Open

Fix dotplot vcenter=0 ignored due to falsy check#295
PauBadiaM wants to merge 1 commit intomainfrom
fix/dotplot-vcenter-zero

Conversation

@PauBadiaM
Copy link
Copy Markdown
Collaborator

Summary

  • Fix if vcenter:if vcenter is not None: in _dotplot.py so that vcenter=0 correctly applies TwoSlopeNorm
  • Add vcenter=0 to the parametrized test to prevent regression

Closes #293

Test plan

  • tests/pl/test_dotplot.py passes with all 3 parametrized values (None, 0, 3)

🤖 Generated with Claude Code

`if vcenter:` evaluates to False when vcenter=0, so TwoSlopeNorm was
never applied. Changed to `if vcenter is not None:` and added vcenter=0
to the parametrized test.

Closes #293

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.

dc.pl.dotplot: vcenter=0 does not center white color at zero when using RdBu_r colormap

1 participant