Commit 1dbb8817 authored by Theophile GENTILHOMME's avatar Theophile GENTILHOMME

Merge branch 'theo-cli' of gitlab.idiap.ch:bob/bob.measure into theo-cli

parents 88e40fa0 0a362831
Pipeline #19149 passed with stage
in 33 minutes and 35 seconds
......@@ -406,7 +406,7 @@ def style_option(**kwargs):
plt.style.use(value)
return value
return click.option(
'--style', multiple=True, type=click.types.Choice(plt.style.available),
'--style', multiple=True, type=click.types.Choice(sorted(plt.style.available)),
help='The matplotlib style to use for plotting. You can provide '
'multiple styles by repeating this option',
callback=callback, **kwargs)(func)
......
......@@ -670,8 +670,8 @@ class Hist(PlotBase):
def _setup_hist(self, neg, pos):
''' This function can be overwritten in derived classes'''
self._density_hist(
pos, label='Positives', alpha=0.5, color='blue', **self._kwargs
pos, label='Positives', alpha=0.5, color='C0', **self._kwargs
)
self._density_hist(
neg, label='Negatives', alpha=0.5, color='red', **self._kwargs
neg, label='Negatives', alpha=0.5, color='C3', **self._kwargs
)
......@@ -104,10 +104,7 @@ def get_colors(n):
cmap = pyplot.cm.get_cmap(name='magma')
return [cmap(i) for i in numpy.linspace(0, 1.0, n + 1)]
# matplotlib 2.0 default color cycler list: Vega category10 palette
return ['#1f77b4', '#ff7f0e', '#2ca02c', '#d62728',
'#9467bd', '#8c564b', '#e377c2', '#7f7f7f',
'#bcbd22', '#17becf']
return ['C0','C1','C2','C3','C4','C5','C6','C7','C8','C9']
def confidence_for_indicator_variable(x, n, alpha=0.05):
'''Calculates the confidence interval for proportion estimates
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment