diff --git a/Histogram1D.h b/Histogram1D.h index 323a9dd..0117a04 100644 --- a/Histogram1D.h +++ b/Histogram1D.h @@ -333,7 +333,7 @@ public: if( 0 <= index1 && index1 <= 2*xBin) yList[ID][index1] += 1; if( 0 <= index1 && index2 <= 2*xBin) yList[ID][index2] += 1; - if( yList[ID][index1] > yMax ) yMax = yList[ID][index1]; + if( showHist[ID] && yList[ID][index1] > yMax ) yMax = yList[ID][index1]; } void Print(unsigned int ID = 0){