Thanks Rene,
I am so sorry… It is a shame I did not read documentation up to the end.
But, one good thing is that it lead me to another question:
How can I fill an histogram up to a certain number of events ?
ch->Draw(“T0-T6+1000>>h”,“T2>100 && T10<100”)
up to, say, 1,000,000 events in the histogram.
(Eventually, I’d like to split my data in histograms, used a fixed number of entries in each histogram)
Well… the previous command will process the first 1,000,000 events in the chain, and fill the histogram according to the cuts I gave. I ended with h containing 518126 entries.
What I’d like to have is exactly 1,000,000 entries in the histogram, without specifying the numbers of events needed.
Maybe it’s impossible, I don’t know…
Indeed, this is not supported directly by TTree::Draw. However you can use the ‘proxy’ mechanism where you pass to TTree::Draw a small script (see TTree::Draw documentation) or you can use directly TTree::MakeProxy or TTree::MakeSelector.