Error in TStatistic

Hi Rooters,
TStatistic is great class in case you need just mean value and RMS. But mean value routine in this class calculate values for each filling. So if 1st value filled with weight=0 its fails, just due to for 1st step =x_0*w_0/w_0 and if w=0 it come to 0/0. Maybe need to implement some cap for this particular case. I just write one complicated code and spend about 2 hours understanding this :frowning:


I have committed (in both 5.34 and 6 versions) a new version of the the Statistic class. It should fix the problem you have found and in addition it also fixes other bugs (e.g. in the Merge function)

Best Regards