Skip to content

Fix major bugs in axis range determination

Maximilian Emanuel Goblirsch-Kolb requested to merge improveEffi into master

This MR fixes a pair of major bugs in the automatic axis range determination:

  • The Fixed flag of the AxisConfig was not being checked, and always interpreted as true - so it was not possible to define "soft" thresholds, as originally intended
  • The Min and Max flags were not being propagated into the GetMinimum/GetMaximum methods of ROOT, meaning soft theshold would not even work without the bug above. This also broke manually overriding the x axis range.

Both should be fixed now. The new (and originally intended) functionality of Min and Max is as follows:

  • If the Fixed flag is false (default), Min / Max represent lower / upper thresholds when dynamically determining the histogram or graph minimum/maximum. This means that only entries above Min and below Max will be considered when determining the histo minimum / maximum, which can be used to remove empty bins (zero content --> Min(1e-8) will veto those) or huge outliers.
  • If the Fixed flag is true, Min/Max directly will be set as the final axis minimum / maximum. Use for example for the final publication version of a plot, when you will need to implement 25 CDS comments demanding a certain range.

Tagging @jojungge @zschilla @pbhattar @iwang as some of the main users, as this may change the "out of the box" plot appearance.

Edited by Maximilian Emanuel Goblirsch-Kolb

Merge request reports