Hi wei,
This is explained in the doc of TTree::Draw:
http://root.cern.ch/root/htmldoc/src/TTree.cxx.html#TTree:Draw
Look at section: "How to obtain more info from TTree::Draw"
The example given is the following: assume aTTree/TNtuple ntuple:
Root > ntuple->Draw("py:px","pz>4");
Root > TGraph *gr = new TGraph(ntuple->GetSelectedRows(),
ntuple->GetV2(), ntuple->GetV1());
Root > gr->Draw("al");
Rene Brun
Xie Wei wrote:
>
> Dear Rooter
>
> My question is if there's a very well correlated scatter plot,
> e.g. x:y from a ntuple, how can I draw a line which pass through all the
> points.
>
> One way to do that is of couse transform this x:y into a 1-D histogram but
> it would be much easier if there's a drawing option in ntuple.
>
> Thank you !
> --Wei
This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:50:36 MET