Drawing the leafs of TTrees

From: Ilya Orlov <Ilya.Orlov_at_cern.ch>
Date: Thu, 21 Aug 2008 16:14:38 +0200


Hello ROOT people,

I'm trying to generate a 2D plot based on the contents of TTree by calling tree->Draw("Amplitude:Time>>graph1","<some conditions>");

Everything is perfect, the line on the plot is wonderful :)

But then I'm trying to save the generated plot to a file from a C function by calling
tree->Draw("Amplitude:Time>>graph1","<some conditions>","groff"); TGraph* gr_tmp = (TGraph*) gDirectory->Get("graph1"); f TGraph* gr1 = (TGraph*) gr_tmp->Clone("ampl_time");

In this case in my output file I see the ampl_time object being of type TH2D and the plot became "diffused" - instead of single line I have the filling of the rectangular regions like in simple 2D histo.

(How) Can I save my plot with the initial parameters so that it could be drawn as a graph but not a histo?

Thanks in advance!

--
Best regards,
Ilya Orlov.

ATLAS experiment, CERN
Electromagnetic LAr end-cap calorimeter group
Received on Thu Aug 21 2008 - 16:14:45 CEST

This archive was generated by hypermail 2.2.0 : Thu Aug 21 2008 - 17:50:01 CEST