csep.utils.plots.plot_poisson_consistency_test

csep.utils.plots.plot_poisson_consistency_test(eval_results, normalize=False, one_sided_lower=False, axes=None, plot_args=None, show=False)[source]

Plots results from CSEP1 tests following the CSEP1 convention.

Note: All of the evaluations should be from the same type of evaluation, otherwise the results will not be

comparable on the same figure.

Parameters:
  • results (list) – Contains the tests results csep.core.evaluations.EvaluationResult (see note above)

  • normalize (bool) – select this if the forecast likelihood should be normalized by the observed likelihood. useful for plotting simulation based simulation tests.

  • one_sided_lower (bool) – select this if the plot should be for a one sided test

  • plot_args (dict) – optional argument containing a dictionary of plotting arguments, with keys as strings and items as described below

Optional plotting arguments:
  • figsize: (list/tuple) - default: [6.4, 4.8]

  • title: (str) - default: name of the first evaluation result type

  • title_fontsize: (float) Fontsize of the plot title - default: 10

  • xlabel: (str) - default: ‘X’

  • xlabel_fontsize: (float) - default: 10

  • xticks_fontsize: (float) - default: 10

  • ylabel_fontsize: (float) - default: 10

  • color: (float/None) If None, sets it to red/green according to _get_marker_style() - default: ‘black’

  • linewidth: (float) - default: 1.5

  • capsize: (float) - default: 4

  • hbars: (bool) Flag to draw horizontal bars for each model - default: True

  • tight_layout: (bool) Set matplotlib.figure.tight_layout to remove excess blank space in the plot - default: True

Returns:

ax (matplotlib.pyplot.axes object)