ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
TrackTupleInfo Class Reference
Inheritance diagram for TrackTupleInfo:
Collaboration diagram for TrackTupleInfo:

Public Member Functions

 TrackTupleInfo (TFile *)
 

Private Attributes

TNtuple * m_Tracktuple
 

Detailed Description

Definition at line 3819 of file TRTCalib_makeplots.cxx.

Constructor & Destructor Documentation

◆ TrackTupleInfo()

TrackTupleInfo::TrackTupleInfo ( TFile *  file)

Definition at line 3828 of file TRTCalib_makeplots.cxx.

3829 {
3830 
3831  m_Tracktuple = (TNtuple *)file->Get("tracktuple");
3832  if (!m_Tracktuple)
3833  throw(string("tracktuple not found!"));
3834 
3835  this->SetName("c1");
3836  this->Divide(1, 2, 0.01, 0.01);
3837  ((TPad *)this->GetPrimitive("c1_1"))->SetLogy();
3838  this->cd(1);
3839  TH1F *trackhits = new TH1F("trackhits", "Accepted hits per track", 60, -0.5, 59.5);
3840  TH1F *trackhits1 = new TH1F("trackhits1", "Accepted hits per track BarrelA", 60, -0.5, 59.5);
3841  TH1F *trackhits2 = new TH1F("trackhits2", "Accepted hits per track EndcaoA", 60, -0.5, 59.5);
3842  TH1F *trackhits3 = new TH1F("trackhits3", "Accepted hits per track BarrelC", 60, -0.5, 59.5);
3843  TH1F *trackhits4 = new TH1F("trackhits4", "Accepted hits per track EndcaoC", 60, -0.5, 59.5);
3844 
3845  TH1F *eventphase = new TH1F("eventphase", "Event Phase", 80, -18, -1);
3846  TH1F *eventphase1 = new TH1F("eventphase1", "Eventphase1", 80, -18, -1);
3847  TH1F *eventphase2 = new TH1F("eventphase2", "Eventphase2", 80, -18, -1);
3848  TH1F *eventphase3 = new TH1F("eventphase3", "Eventphase3", 80, -18, -1);
3849  TH1F *eventphase4 = new TH1F("eventphase4", "Eventphase4", 80, -18, -1);
3850 
3851  m_Tracktuple->Draw("nhits>>trackhits");
3852 
3853  m_Tracktuple->Draw("nhits>>trackhits1", "-log(tan(theta/2))>0 && -log(tan(theta/2))< 1 ", "same");
3854  m_Tracktuple->Draw("nhits>>trackhits2", "-log(tan(theta/2))>1", "same");
3855  m_Tracktuple->Draw("nhits>>trackhits3", "-log(tan(theta/2))<0 && -log(tan(theta/2))> -1 ", "same");
3856  m_Tracktuple->Draw("nhits>>trackhits4", "-log(tan(theta/2))<-1 ", "same");
3857  trackhits1->SetLineColor(2);
3858  trackhits2->SetLineColor(3);
3859  trackhits3->SetLineColor(4);
3860  trackhits4->SetLineColor(5);
3861  trackhits1->Draw("same");
3862  trackhits2->Draw("same");
3863  trackhits3->Draw("same");
3864  trackhits4->Draw("same");
3865  TLegend *leg1 = new TLegend(0.7155172, 0.1038136, 0.8965517, 0.2542373, nullptr, "brNDC");
3866  leg1->AddEntry(trackhits, "all tracks", "l");
3867  leg1->AddEntry(trackhits1, "0 < eta < 1", "l");
3868  leg1->AddEntry(trackhits2, "eta > 1", "l");
3869  leg1->AddEntry(trackhits3, "-1 < eta < 0", "l");
3870  leg1->AddEntry(trackhits4, "eta < -1", "l");
3871  leg1->SetTextSize(0.03);
3872  leg1->Draw();
3873 
3874  trackhits->SetTitle(Form("Accepted precission hits per track (%lli tracks in total)", m_Tracktuple->GetEntries()));
3875  trackhits->GetXaxis()->SetTitle("accepted precission hits");
3876  trackhits->GetYaxis()->SetTitle("No. tracks");
3877  this->SetName("c1");
3878  this->cd(2);
3879  ((TPad *)this->GetPrimitive("c1_2"))->SetLogy();
3880 
3881  m_Tracktuple->Draw("epold>>eventphase");
3882  m_Tracktuple->Draw("epold>>eventphase1", "-log(tan(theta/2))>0 && -log(tan(theta/2))< 1", "same");
3883  m_Tracktuple->Draw("epold>>eventphase2", "-log(tan(theta/2))>1", "same");
3884  m_Tracktuple->Draw("epold>>eventphase3", "-log(tan(theta/2))<0 && -log(tan(theta/2))> -1", "same");
3885  m_Tracktuple->Draw("epold>>eventphase4", "-log(tan(theta/2))<-1", "same");
3886 
3887  eventphase1->SetLineColor(2);
3888  eventphase2->SetLineColor(3);
3889  eventphase3->SetLineColor(4);
3890  eventphase4->SetLineColor(5);
3891 
3892  eventphase->SetTitle("Eventphase");
3893  eventphase->GetXaxis()->SetTitle("eventphase");
3894  eventphase->GetYaxis()->SetTitle("No. tracks");
3895 
3896  TLegend *leg2 = new TLegend(0.7155172, 0.1038136, 0.8965517, 0.2542373, nullptr, "brNDC");
3897  leg2->AddEntry(trackhits1, "0 < eta < 1", "l");
3898  leg2->AddEntry(trackhits2, "eta > 1", "l");
3899  leg2->AddEntry(trackhits3, "-1 < eta < 0", "l");
3900  leg2->AddEntry(trackhits4, "eta < -1", "l");
3901  leg2->SetTextSize(0.03);
3902  leg2->Draw();
3903 }

Member Data Documentation

◆ m_Tracktuple

TNtuple* TrackTupleInfo::m_Tracktuple
private

Definition at line 3825 of file TRTCalib_makeplots.cxx.


The documentation for this class was generated from the following file:
file
TFile * file
Definition: tile_monitor.h:29
TrackTupleInfo::m_Tracktuple
TNtuple * m_Tracktuple
Definition: TRTCalib_makeplots.cxx:3825
calibdata.cd
cd
Definition: calibdata.py:51
python.TrigEgammaMonitorHelper.TH1F
def TH1F(name, title, nxbins, bins_par2, bins_par3=None, path='', **kwargs)
Definition: TrigEgammaMonitorHelper.py:24