7 float par_refYiled=2000;
9 void plTpcChi2(
int mxR=2) {
10 gStyle->SetPalette(1,0);
11 gStyle->SetOptStat(0);
12 char *inpList=
"pp500-hist.list";
13 printf(
" read %d runs from '%s'\n",mxR, inpList);
14 FILE *fd=fopen(inpList,
"r"); assert(fd);
15 cw=
new TCanvas(); cw->Divide(1,3);
16 hTr=
new TH1F(
"hTr",
" # of glob tracks w/ pT>1 GeV/c per run; run index",mxR,0,mxR+1); hTr->SetMinimum(10);
17 hCh=
new TH2F(
"hCh",
"chi2/dof glob tracks w/ pT>1 GeV/c per run; run index;chi2/dof",mxR,0,mxR+1,30,0,3.);
18 hChm=
new TH1F(
"hTr",
" mean chi2/dof glob tracks w/ pT>1 GeV/c per run; run index",mxR,0,mxR+1); hChm->SetMinimum(0.5);
19 cw->cd(1); hTr->Draw(); gPad->SetLogy();
20 cw->cd(2); hChm->Draw();
21 cw->cd(3); hCh->Draw(
"colz"); hChm->Draw(
"same");
27 int ret= fscanf(fd,
"%s",txt);
29 char* i=strstr(txt,
"/");
34 int fill=atoi(cFill+1);
40 printf(
"%d %s, %d %s %s %d\n",nR,txt,i-txt,cRun,cFill,fill);
47 for(
int ic=2;ic<=3;ic++) {
49 ln=
new TLine(0,1,nR,1); ln->SetLineColor(35); ln->SetLineStyle(2);
55 void addRun(
char *cFill,
char *cRun) {
56 TString pathIn=
"data-ofl/";
57 TString inFile=pathIn+cRun+
".wana.hist.root";
58 TFile *fd=
new TFile(inFile);
59 if(fd->IsOpen()==0)
return;
63 TH1F *h1=fd->Get(
"muTrch2"); assert(h1);
66 float nTr=h1->Integral();
67 float chm=h1->GetMean();
71 float weight=par_refYiled/nTr;
73 TAxis *ax=h1->GetXaxis(); assert(ax);
74 for(
int k=1; k<ax->GetNbins(); k++) {
75 float x=h1->GetBinCenter(k);
76 float val=h1->GetBinContent(k);
77 hCh->Fill(nR,x,val*weight);
88 void drawNewFill(
char *cFill) {
89 printf(
"draw fill=%s\n",cFill);
93 ln=
new TLine(nR,0,nR,2*par_refYiled); ln->SetLineColor(kMagenta);
94 cw->cd(1); ln->Draw();
95 tx=
new TText(nR+off,20,cFill); tx->SetTextAngle(90); tx->Draw();
96 tx->SetTextSize(0.06);
99 ln=
new TLine(nR,0,nR,5); ln->SetLineColor(kMagenta);
100 cw->cd(2); ln->Draw();
101 tx=
new TText(nR+off,0.6,cFill); tx->SetTextAngle(90); tx->Draw();
102 tx->SetTextSize(0.06);
105 ln=
new TLine(nR,0,nR,3); ln->SetLineColor(kMagenta);
106 cw->cd(3); ln->Draw();
107 tx=
new TText(nR+off,2,cFill); tx->SetTextAngle(90); tx->Draw();
108 tx->SetTextSize(0.06); tx->SetTextColor(kMagenta);