Draw a varible over subset of events

Dear Rooters,

Suppost that I have a tree with large number of event (~1M). The tree contains a leaf jet_pt … How can I quick draw of jet_pt of 1000 events at the interpreter?. I mean how can I modify this code to draw jet_pt over 1000 events?

root -l Sample/CaloCalibTree.root
root[1] CaloCalibTree->Draw(“jet_pt”)

Thank you

Hi,

that’s what we have documentation for :slight_smile: Check root.cern.ch/root/html/TTree#TTree:Draw. Hint: you probably care about the parameter called “nentries”.

Cheers, Axel.

Thank you Axel
This command works perfectly!
CaloCalibTree->Draw(“jet_pt”, “”, “”, 1000)
Cheers,
Duong