-
Notifications
You must be signed in to change notification settings - Fork 18
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
A clear and concise description of what the bug is.
Similar to #19 when plotting 2 models it sometimes happens that the colours for the 2nd model aren't consistent due to the colour cycle not being properly updated in the 1st call.
This was introduced through #21 by switching from direct calls to ax.plot([], [])
to only passing x=[]
(but only to one function).
To Reproduce
ns1 = NestedSamples(root="./tests/example_data/pc")
ns2 = NestedSamples(root="./tests/example_data/pc")
fig, axes = make_2d_axes(['x0', 'x1', 'x2', 'x3'])
ns1.plot_2d(axes=axes, types={'diagonal': None, 'lower': 'kde', 'upper': 'kde'}, label='foo')
ns2.plot_2d(axes=axes, types={'diagonal': 'kde', 'lower': 'kde', 'upper': 'scatter'}, diagonal_kwargs={'ls': '--'}, upper_kwargs={'alpha': 0.3}, label='bar')
Expected behavior
In the above image:
- the dashed lines in the diagonal plots should be orange
- the scatter plots in the upper plots should be orange
Additional context
-
In the diagonal case this must be due to somehow nothing being drawn in the 1st call where
diagonal=None
. -
In the 2D case this has to do with
ax.plot
andax.scatter
not sharing the same colour cycle, so both have to be called every time.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working