Skip to content

Commit

Permalink
Fix boxplot z-order in plot_paired (#442)
Browse files Browse the repository at this point in the history
  • Loading branch information
sbwiecko authored Oct 4, 2024
1 parent b1488dd commit c93ec4b
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/pingouin/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -540,9 +540,17 @@ def plot_paired(
if boxplot_in_front:
_boxplot_kwargs.update(
{
"boxprops": {"zorder": 2},
"whiskerprops": {"zorder": 2},
"zorder": 2,
"boxprops": {"zorder": 3}, # Boxplot on top
"whiskerprops": {"zorder": 3},
"zorder": 3,
}
)
else:
_boxplot_kwargs.update(
{
"boxprops": {"zorder": 1}, # Boxplot behind
"whiskerprops": {"zorder": 1},
"zorder": 1,
}
)

Expand Down

0 comments on commit c93ec4b

Please sign in to comment.