Fill TH2poly2 with 2 histograms

ROOT Version: 6.XX
Platform: linux
Compiler: Not Provided

Now, I have 2 TH1 files. I want to fill them into a TH2Poly.
Should I just use TH2Poly:Add(h1,h2) which seems of no use. So I want to know if there is a simple way to do it ?


I am not fuse I fully understand what you are trying to do …
TH2Poly inherits for TH1 via its TH2 inheritance. As the Add method makes no sense
for a TH2Poly it has been made dummy .
what do you mean by " I want to fill them into a TH2Poly" ?

sorry for my dummy vague expression. Now I have 2 distributions of leading tau and sub leading-tau. I don’t know how to turn them into the plots attached 123

I have read the related file in $ROOTSYS/tutorials/hist/th2xx. they made me a little confused.
So i want to know if there a simple approach to do it without a filling-loop.
Thanks! I am trying …

What kind of histograms are they ?

They are TH1D. I find a useful example “draw2dopt.C”. Maybe i should follow it.
Thanks for your patience ,couet!

You cannot produce a TH2, like the one in the image you posted, from two TH1.

Yeah, you are right. I take it in a wrong way. Thanks.

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