It is possible to compare weighted with weighted histograms,
and weighted with unweighted histograms, but only
if HBOOK
has been instructed to maintain the necessary
information by appropriate calls (before filling) to
HBARX.
However it is not possible to take into account underflow
or overflow bins if the events are weighted.
If there is saturation
(more than the maximum allowed contents in one or more bins),
the probability PROB
is calculated as if the bin contents
were exactly
at their maximum value, ignoring the saturation.
This usually will result in a higher value of PROB
than would
be the case if the memory allowed the full contents to be stored,
but not always.
It should therefore be realized that the results of HDIFF are
not accurate when there is saturation, and it is the user's
responsability to avoid this condition.
Routine HDIFF cannot work if the events are weighted,
since, in the current version of HBOOK
, the necessary information
is not maintained.
HDIFF will also refuse to compare 2-dimensional histograms if
there is saturation, since it does not have enough information
in this case.