[ROOT] htemp in compiled mode

From: Wolfgang Korsch (korsch@helium3.pa.uky.edu)
Date: Mon Aug 13 2001 - 03:00:34 MEST


Dear ROOTers,
 I have an object TTree (nt) which contains a variable x. Now I want to draw
and pipe x into a 1d histgram after some cuts. Within ROOT I do:

root> nt->Draw("x","cuts");

As far as I understand this automatically creates a temporary hist htemp.
So, if I type 

root> htemp->GetEntries(); 

I get the number of events after applying the above cut. This works
fine within ROOT.

Now I have a compiled version of my code. Inside the code I have
nt->Draw("x","cuts") which works as expected, i.e. it draws the 
histogram in my canvas. But now "htemp->GetEntries" returns always
"0". Even explicit piping (nt->Draw("x>>somehist","cuts")) doesn't
work.

Does anybody have an idea how I can access the number of events after
the cuts?

Thanks.

Wolfgang

P.S. I use ROOT 3.01/06 on RH 7.1



This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:50:57 MET