Is there a way to force TTree Draw to produce TH1 histogram for a 2-dim draw (e.g. “par1:par2”) instead of default TH2?
I use ROOT as a library in a c++ application.
I am doing this:
tree->Draw(What, Cond, Opt)
and then
TH1* tmpHist = dynamic_cast<TH1*>(gDirectory->Get(“htemp”))
The What parameter contains “>>htemp()”
With empty Opt a scatter plot is produced.
With “prof” option, a TProfile is created but it shows true points together with artificially-added zero points.
And it seems it should be possible to do what I need since the Root browser can do this: if Opt is set to “LP”, a line is indeed drawn, while using this option in the approach described above changes nothing.