2Double_t
x[10]={.1,.2,.3,.4,.5,.6,.7,.8,.9,1.};
10for(Int_t i=0;i<10;i++){
12 strcpy(filename,
file);
13 strcat(filename,name);
16 runinfo->Draw(
"runinfo_ngood",
"runinfo_ngood>0.5");
17 effpt[i]=htemp->GetEntries()/
eventNo;
22for (Int_t i=0;i<10;i++){
23 errpt[i]=sqrt(effpt[i]*(1.-effpt[i])/
eventNo);
28TGraph *gr1 =
new TGraphErrors(10,
x,effpt,
errx,errpt);
30TCanvas *c1 =
new TCanvas (
"c1",
"pioneff",100,10,600,400);
31TMultiGraph *mg =
new TMultiGraph();
35mg->SetTitle(
"pioneff");
40mg->GetYaxis()->SetRangeUser(0,1);
41mg->GetXaxis()->SetTitle(
"Pt/GeV");
42mg->GetYaxis()->SetTitle(
"Eff");
44TLegend *
legend=
new TLegend(0.7,0.65,0.85,0.75);
45legend->AddEntry(gr1,
"pion_Pt",
"l");
sprintf(cut,"kal_costheta0_em>-0.93&&kal_costheta0_em<0.93&&kal_pxy0_em>=0.05+%d*0.1&&kal_pxy0_em<0.15+%d*0.1&&NGch>=2", j, j)
TFile f("ana_bhabha660a_dqa_mcPat_zy_old.root")
void Single_trkeff_pt(char *file="Single")