testShowCFD.cxx 668 Bytes
Newer Older
1 2 3 4 5 6 7
void testShowCFD()
{

	gSystem->Load("../libData.so");

	const Long64_t kFirstEvent = 128;

8
	TFile fr("../data/dataDSR4/analysis_08_2_CFD02_06.root");
9 10 11 12 13
	TTree *tr = (TTree*)fr.Get("atree");

	AEvent *revent = new AEvent();
	tr->SetBranchAddress("Ach0.",&revent);

14
	TGraph *gr[12];
15 16

	//loop over events
17
	for (Int_t i = 0; i < 12; i++) {
18 19
		gr[i] = 0;
		tr->GetEntry(i+kFirstEvent);
20
		gr[i] = new TGraph(*revent->GetGraphCFD());
21 22 23
	}//for over events


24
	TCanvas *c1 = new TCanvas("c1","CFD implementation",10,10,1000,600);
25
	c1->Divide(3,4);
26

27
	for (Int_t i = 0; i < 12; i++) {
28
		c1->cd(i+1);
29
		gr[i]->Draw("");
30 31 32 33 34
	}

//	c1->cd(2);
//	tr->Draw("gAmp.Draw()","","goff",1,124);
}