Improve trending plots, particularly wfe_histogram arrows display #870
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Improves the
trending.wfe_histogram_plot
arrow markers to show corrections.matplotlib.annotate
to draw the arrows, instead of separate calls to plot lines and draw triangle markers. This ultimately is cleaner but ended up taking a while to figure out since there's a ridiculously complicated set of options to the arrow-drawing functions.min_wfe
andmax_wfe
options to that function, which can be used to directly set custom min and max ranges if the defaults aren't suitable in some particular case. The histogram and cumulative histogram display is updates to clip values, such that values outside of min and max are still included in the histogram at the extreme bottom or top bin of the histogram, respectively.Example output:
Separately, this PR also has a minor fix to some unrelated display issues elsewhere in
trending.py
, by settingclip_on=True
in a couple function calls, to prevent labels being drawn outside of axes sometimes depending on x and y ranges there. This is mostly unrelated but is convenient to combine into this same PR.