Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 11:58:24

0001 
0002 {
0003     gROOT->ProcessLine(".x /home/darinb/CMSStyle.C");
0004     TFile f("All.root");
0005 
0006     TTree *DiffGains = (TTree*)f->Get("DiffGains");
0007     TTree *DiffMatrix = (TTree*)gDirectory->Get("DiffMatrix");
0008     TTree *DiffPeds = (TTree*)gDirectory->Get("DiffPeds");
0009     TTree *DiffXtalk = (TTree*)gDirectory->Get("DiffXtalk");
0010 
0011     TH2F h2("h2","",500,-1,1,230000,0,230000);
0012     h2->SetMarkerSize(.1);
0013     h2->SetStats(0);
0014 
0015     TLatex* txt =new TLatex(-.9,200000, "#frac{new - old}{old} ");
0016     txt->SetTextFont(132);
0017     txt->SetTextSize(0.04);
0018     h2->GetXaxis()->SetTitleSize(.05);
0019     h2->GetYaxis()->SetTitleSize(.05);
0020     h2->GetYaxis()->SetTitle("Strip Index");
0021 
0022     h2->GetXaxis()->SetTitle("Gains (Relative Change)");
0023                                  // txt->Draw();
0024     DiffGains->Draw("index:diffGains>>h2");
0025     c1.SetGridx(1);
0026 
0027     c1->Print("diffGains_ind.png");
0028 
0029     h2->GetXaxis()->SetTitle("Pedestals (Relative Change)");
0030                                  // txt->Draw();
0031     DiffPeds->Draw("index:diffPeds>>h2");
0032     c1->Print("diffPeds_ind.png");
0033 
0034     h2->GetXaxis()->SetTitle("CrossTalk Right (Relative Change)");
0035                                  //txt->Draw();
0036     DiffXtalk->Draw("index:diffXtalkR>>h2");
0037     c1->Print("diffXtalkR_ind.png");
0038 
0039     h2->GetXaxis()->SetTitle("CrossTalk Right Int (Relative Change)");
0040                                  //txt->Draw();
0041     DiffXtalk->Draw("index:diffIntR>>h2");
0042     c1->Print("diffIntR_ind.png");
0043 
0044     h2->GetXaxis()->SetTitle("CrossTalk Left (Relative Change)");
0045                                  //txt->Draw();
0046     DiffXtalk->Draw("index:diffXtalkL>>h2");
0047     c1->Print("diffXtalkL_ind.png");
0048 
0049     h2->GetXaxis()->SetTitle("CrossTalk Left Int (Relative Change)");
0050                                  // txt->Draw();
0051     DiffXtalk->Draw("index:diffIntL>>h2");
0052     c1->Print("diffIntL_ind.png");
0053 
0054     //  DiffMatrix->Draw("index:diffElem33");
0055     //  c1->Print("diffElem33_ind.png");
0056     //  DiffMatrix->Draw("index:diffElem34");
0057     //  c1->Print("diffElem34_ind.png");
0058     //  DiffMatrix->Draw("index:diffElem44");
0059     //  c1->Print("diffElem44_ind.png");
0060     //  DiffMatrix->Draw("index:diffElem35");
0061     //  c1->Print("diffElem35_ind.png");
0062     //  DiffMatrix->Draw("index:diffElem45");
0063     //  c1->Print("diffElem45_ind.png");
0064     //  DiffMatrix->Draw("index:diffElem55");
0065     //  c1->Print("diffElem55_ind.png");
0066     //  DiffMatrix->Draw("index:diffElem46");
0067     //  c1->Print("diffElem46_ind.png");
0068     //  DiffMatrix->Draw("index:diffElem56");
0069     //  c1->Print("diffElem56_ind.png");
0070     //  DiffMatrix->Draw("index:diffElem66");
0071     //  c1->Print("diffElem66_ind.png");
0072     //  DiffMatrix->Draw("index:diffElem57");
0073     //  c1->Print("diffElem57_ind.png");
0074     //  DiffMatrix->Draw("index:diffElem67");
0075     //  c1->Print("diffElem67_ind.png");
0076     //  DiffMatrix->Draw("index:diffElem77");
0077     //  c1->Print("diffElem77_ind.png");
0078 
0079     /// Histograms.
0080 
0081     c1->SetLogy();
0082 
0083     TH1F h("h", "", 500, -1, 1);
0084     h->SetStats(0);
0085 
0086     TLatex* txt2 =new TLatex(-.9,1000, "#frac{new - old}{old} ");
0087     txt2->SetTextFont(132);
0088     txt2->SetTextSize(0.04);
0089 
0090     h->GetXaxis()->SetTitle("Gains (Relative Change)");
0091                                  //  txt2->Draw();
0092     DiffGains->Draw("diffGains>>h");
0093     c1->Print("diffGains.png");
0094 
0095     h->GetXaxis()->SetTitle("Pedestals (Relative Change)");
0096                                  //txt2->Draw();
0097     DiffPeds->Draw("diffPeds>>h");
0098     c1->Print("diffPeds.png");
0099 
0100     h->GetXaxis()->SetTitle("CrossTalk - Right (Relative Change)");
0101                                  //        txt2->Draw();
0102     DiffXtalk->Draw("diffXtalkR>>h");
0103     c1->Print("diffXtalkR.png");
0104 
0105     h->GetXaxis()->SetTitle("CrossTalk - Right Int (Relative Change)");
0106                                  //txt2->Draw();
0107     DiffXtalk->Draw("diffIntR>>h");
0108     c1->Print("diffIntR.png");
0109 
0110     h->GetXaxis()->SetTitle("CrossTalk - Left (Relative Change)");
0111                                  // txt2->Draw();
0112     DiffXtalk->Draw("diffXtalkL>>h");
0113     c1->Print("diffXtalkL.png");
0114 
0115     h->GetXaxis()->SetTitle("CrossTalk - Left Int (Relative Change)");
0116                                  //txt2->Draw();
0117     DiffXtalk->Draw("diffIntL>>h");
0118     c1->Print("diffIntL.png");
0119 
0120     //  DiffMatrix->Draw("diffElem33");
0121     //  c1->Print("diffElem33.png");
0122     //  DiffMatrix->Draw("diffElem34");
0123     //  c1->Print("diffElem34.png");
0124     //  DiffMatrix->Draw("diffElem44");
0125     //  c1->Print("diffElem44.png");
0126     //  DiffMatrix->Draw("diffElem35");
0127     //  c1->Print("diffElem35.png");
0128     //  DiffMatrix->Draw("diffElem45");
0129     //  c1->Print("diffElem45.png");
0130     //  DiffMatrix->Draw("diffElem55");
0131     //  c1->Print("diffElem55.png");
0132     //  DiffMatrix->Draw("diffElem46");
0133     //  c1->Print("diffElem46.png");
0134     //  DiffMatrix->Draw("diffElem56");
0135     //  c1->Print("diffElem56.png");
0136     //  DiffMatrix->Draw("diffElem66");
0137     //  c1->Print("diffElem66.png");
0138     //  DiffMatrix->Draw("diffElem57");
0139     //  c1->Print("diffElem57.png");
0140     //  DiffMatrix->Draw("diffElem67");
0141     //  c1->Print("diffElem67.png");
0142     //  DiffMatrix->Draw("diffElem77");
0143     //  c1->Print("diffElem77.png");
0144 
0145 }