void testShowGraphs() { gSystem->Load("../libData.so"); const Long64_t kFirstEvent = 128; // TFile fr("../data/dataDSR4/Neurad_7_08_NEW.root"); // TFile fr("../data/dataDSR4/analysis_07_8.root"); <<<<<<< HEAD <<<<<<< HEAD // TFile fr("../data/dataDSR4/Neurad_081216_2NEW.root"); // TFile fr("../data/dataTektronix/exp18.root"); ======= ======= TFile fr("../data/dataDSR4/analysis_08_2.root"); >>>>>>> 58f61cb195c6b08755455386b15990ce4c27b599 // TFile fr("../data/dataDSR4/Neurad_081216_2NEW.root"); // TFile fr("../data/dataTektronix/exp18.root"); >>>>>>> 09d9ad17f40ac0af9d228137f715f25ee9ea15ae // TFile fr("../data/dataTektronix/analysisExp7.root"); TTree *tr = (TTree*)fr.Get("atree"); AEvent *revent = new AEvent(); cout << tr->SetBranchAddress("Ach0.",&revent) << endl; TGraph *gr[13]; Double_t t10[13]; Double_t t90[13]; // cout << "warning" << endl; cout << tr->GetEntries() << endl; //loop over events for (Long64_t i = 0; i < 13; i++) { gr[i] = 0; t10[i] = 0; t90[i] = 0; // cout << "warning 1" << endl; // cout << i+kFirstEvent << endl; tr->GetEntry(i+kFirstEvent); // tr->GetEntry(i); // cout << "warning 2" << endl; gr[i] = new TGraph(*revent->GetGraphSignal()); t10[i] = revent->GetT_10(); t90[i] = revent->GetT_90(); // cout << t10[i] << "\t" << t90[i] << endl; // cout << revent->GetEdgeSlope() << endl; }//for over events // cout << "warning 3" << endl; TCanvas *c1 = new TCanvas("c1","test",10,10,1000,600); <<<<<<< HEAD //c1->Divide(3,2); c1->Divide(3,4); ======= //c1->Divide(3,2); c1->Divide(3,4); >>>>>>> 09d9ad17f40ac0af9d228137f715f25ee9ea15ae TF1 *f1 = new TF1("f1name", "[0]+x*[1]"); // TF1 *f1 = new TF1("pol1", ); <<<<<<< HEAD for (Int_t k = 0; k < 6; k++) { // for (Int_t k = 0; k < 12; k++) { ======= for (Int_t k = 0; k < 12; k++) { >>>>>>> 09d9ad17f40ac0af9d228137f715f25ee9ea15ae c1->cd(k+1); gr[k]->Draw("AL*"); //cout << t10[k] << "\t" << t90[k] << endl; //f1->SetRange(t10[k], t90[k]); //gr[k]->Fit(f1, "RQ"); } // c1->cd(2); // tr->Draw("gAmp.Draw()","","goff",1,124); }