All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TCHist.cxx
Go to the documentation of this file.
1 #include "art_root_io/TFileService.h"
2 #include "art/Framework/Services/Registry/ServiceHandle.h"
4 
5 #include <cmath>
6 #include "TH1F.h"
7 #include "TProfile.h"
8 
9 namespace tca {
10 
11  void HistStuff::CreateHists(art::ServiceHandle<art::TFileService const>& tfs)
12  {
13 
14  fTruT[0] = tfs->make<TH1F>("TruT_El","True KE (MeV) - Electrons", 100, 0, 1000);
15  fTruT[1] = tfs->make<TH1F>("TruT_Mu","True KE (MeV) - Muons", 100, 0, 10000);
16  fTruT[2] = tfs->make<TH1F>("TruT_Pi","True KE (MeV) - Pions", 100, 0, 1000);
17  fTruT[3] = tfs->make<TH1F>("TruT_Ka","True KE (MeV) - Kaons", 100, 0, 10000);
18  fTruT[4] = tfs->make<TH1F>("TruT_Pr","True KE (MeV) - Protons", 100, 0, 1000);
19 
20  fEff_T[0] = tfs->make<TProfile>("Eff_T_El","Eff vs T(MeV) - Electrons", 20, 0, 1000);
21  fEff_T[1] = tfs->make<TProfile>("Eff_T_Mu","Eff vs T(MeV) - Muons", 20, 0, 10000);
22  fEff_T[2] = tfs->make<TProfile>("Eff_T_Pi","Eff vs T(MeV) - Pions", 20, 0, 1000);
23  fEff_T[3] = tfs->make<TProfile>("Eff_T_Ka","Eff vs T(MeV) - Kaons", 20, 0, 1000);
24  fEff_T[4] = tfs->make<TProfile>("Eff_T_Pr","Eff vs T(MeV) - Protons", 20, 0, 1000);
25 
26  fPur_T[0] = tfs->make<TProfile>("Pur_T_El","Pur vs T(MeV) - Electrons", 20, 0, 1000);
27  fPur_T[1] = tfs->make<TProfile>("Pur_T_Mu","Pur vs T(MeV) - Muons", 20, 0, 10000);
28  fPur_T[2] = tfs->make<TProfile>("Pur_T_Pi","Pur vs T(MeV) - Pions", 20, 0, 1000);
29  fPur_T[3] = tfs->make<TProfile>("Pur_T_Ka","Pur vs T(MeV) - Kaons", 20, 0, 1000);
30  fPur_T[4] = tfs->make<TProfile>("Pur_T_Pr","Pur vs T(MeV) - Protons", 20, 0, 1000);
31 
32  }
33 
34 
35 } // tca
TH1F * fTruT[5]
Definition: TCHist.h:25
TProfile * fPur_T[5]
Definition: TCHist.h:27
void CreateHists(art::ServiceHandle< art::TFileService const > &tfs)
Definition: TCHist.cxx:11
TProfile * fEff_T[5]
Definition: TCHist.h:26
art::ServiceHandle< art::TFileService > tfs