{ TString name1 = "../GoodParam/desaturation_position.txt"; ifstream fin1(name1); gROOT->SetStyle("Plain"); gStyle->SetOptStat(0); gStyle->SetOptFit(0); gStyle->SetFuncColor( kRed ); Float_t tp[48][4]; char *s = new char[1]; Int_t idummy; Float_t p0,p1,p2,p3; for (int i=0; i<48; i++) { fin1>>idummy>>p0>>p1>>p2>>p3; cout<<" "<SetLineColor(kRed); for (Int_t ii=1; ii<20; ii++) { Float_t xb = ii*20.; Float_t yhelp = f1[i]->Eval(xb); cout<SetXTitle("adccorr"); hr->SetYTitle("f_pos"); hr->Draw(); f1[i]->Draw("same"); //gPad->SetLogy(); gPad->SetGrid(); c->Update(); gets(s); } //========================================================================== //========================================================================== //========================================================================== TCanvas *c1 = new TCanvas("c1","histograms1",1100,800); c1->Divide(8,6); TF1 *f1[48]; for (Int_t i=0; i<48; i++) { cout<<"PMT "<cd(i+1); TH2F *hr = new TH2F("hr","",2,0,1000,2,0,1000); hr->SetXTitle("adccorr"); hr->SetYTitle("f_pos"); hr->Draw(); f1[i]->Draw("same"); //gPad->SetLogy(); gPad->SetGrid(); } } }