How to use a colz with a variable of a chain

Good afternoon!

I’m trying to use a the colz to analyse a chain. What I now is if it’s possible doing a TH2F with option colz, using an other variable of the chain (in this case, Step_AccumulatedEnergyDeposited).

The makeclass file is attached.

Best regards
analyseClass.h (13.5 KB) analyseClass.C (7.0 KB)

ROOT Version: 6.18.00
Platform: UBUNTU 18.04
Compiler: Not Provided


In your code, you already create, fill and draw several TH2F histograms so what is your problem with another one?

Thanks @Wile_E_Coyote for the fast answer.

What I want is that the colors of one of the TH2F (can->cd(2)) in colz return the values data for the variable Step_AccumulatedEnergyDeposited. It’s possible?

Best Regards

Currently the “analyse1” histogram is drawn there so the colors correspond to the number of counts in its bins.

Maybe you want a TGraph2D or a TProfile2D or a TH3.

Ok maybe it works some of these. I’m doing a try and return to say if is what I wanted. In the TGraph2D there was a manner to define the bins of the graphic?

Thanks again

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.