Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions ultraplot/axes/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -2707,13 +2707,6 @@ def _parse_cmap(

# Create the continuous normalizer.
norm = _not_none(norm, "div" if "diverging" in trues else "linear")
# If using a diverging norm, fair=True, and vcenter not set, default to midpoint
if norm in ("div", "diverging") or "diverging" in trues:
fair = norm_kw.get("fair", True) # defaults to True
vcenter = norm_kw.get("vcenter", 0)
if fair and vcenter is None and vmin is not None and vmax is not None:
vcenter = 0.5 * (vmin + vmax)
norm_kw["vcenter"] = vcenter
if isinstance(norm, mcolors.Normalize):
norm.vmin, norm.vmax = vmin, vmax
else:
Expand Down Expand Up @@ -2946,6 +2939,7 @@ def _parse_level_lim(
f"Incompatible arguments vmin={vmin!r}, vmax={vmax!r}, and "
"symmetric=True. Ignoring the latter."
)

return vmin, vmax, kwargs

def _parse_level_num(
Expand Down
37 changes: 0 additions & 37 deletions ultraplot/tests/test_color.py

This file was deleted.