Skip to content
Snippets Groups Projects
Select Git revision
  • a265ee2e4c0976b3e9bd62d55c9ca20ee14811d1
  • master default
  • yezhenyu-btof-20210520
  • 41-detailed-zero-degree-calorimeter-hcal
  • testBranchRobin
  • 73-pion-rejection-yr-benchmark
  • default_visibilities
  • view_update
  • wdconinc-ecal-testing
  • 65-trigger-detector-benchmarks
  • upstream_trigger
  • 14-implement-cb_vtx_endcaps
  • 28-implement-ffi_offm_trk-2
  • 32-implement-ffi_rpot_d2
  • 27-implement-fi_b0_emcal
  • 15-implement-cb_sidiscs
  • 24-implement-ci_hcal
  • fix_ci_GEM
  • 8-implement-cb_ctd
  • Implement_AMEGOX_layers
  • yezhenyu_work_master
  • v0.2.0
  • v0.1.0
23 results

cb_Solenoid.xml

Blame
  • comptrackxy.C 1.36 KiB
    void comptrackxy(Int_t run)
    {
      TFile* f = new TFile(Form("hodtest_%d.root",run));
      cout << "hcana root file " << Form("hodtest_%d.root",run) << endl;
      TH2F* h = trx_vs_try;
    
      TFile* f1 = new TFile(Form("%d_hbk.root",run));
      cout << "Engine root file " << Form("%d_hbk.root",run) << endl;
      TH2F* h1;
      switch (run) {
      case 50017 :
      //    h1 = h212;   //A+
        break;
      default :
        h1 = h419;   //Y vs Y
      }
    
      TCanvas *c1 = new TCanvas("c1", "Shower Largest cluster X", 1000, 667);
    
      //  gPad->SetLogy();
    
      h1->SetMarkerColor(kGreen);
      //  h1->SetLineColor(kGreen);
      h1->Draw();
    
      h->SetMarkerColor(kBlue);
      //  h->SetFillStyle(0);
      //  h->SetLineWidth(2);
      h->Draw("same");
    
      /*
      TLatex l;
      l.SetTextSize(0.04);
      Float_t maxy = h1->GetBinContent(h1->GetMaximumBin());
      Float_t xmin = h1->GetXaxis()->GetXmin();
      Float_t xmax = h1->GetXaxis()->GetXmax();
      Float_t xt = xmin + 0.67*(xmax-xmin);
    
      l.SetTextColor(kGreen);
      l.DrawLatex(xt,0.095*maxy,"Engine");
      l.SetTextColor(kBlue);
      l.DrawLatex(xt,0.045*maxy,"hcana");
      */
    
      // Difference between the histograms.
    
      TCanvas *c2 = new TCanvas("c2", "X differences", 1000, 667);
    
      TH1F* dif = h->Clone();
    
      dif->Add(h,h1,1.,-1.);
    
      //  dif->SetTitle("X Difference");
      //  dif->SetFillColor(kRed);
      //  dif->SetLineColor(kRed);
      //  dif->SetLineWidth(1);
      //  dif->SetFillStyle(1111);
      dif->Draw("LEGO2");
    }