LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
plot_hist.C File Reference

Go to the source code of this file.

Functions

TFile f ("testem6_0.root")
 
gPad SetLogy ()
 
h7 SetMinimum (minY)
 
h7 SetMaximum (maxY)
 
h7 GetXaxis () -> SetLimits(std::log10(minE), std::log10(maxE))
 
h7 SetTitle ("Comparison of e+ Annihilation Processes(totcrsPerAtom)")
 
h7 GetYaxis () -> SetTitle("microbarn")
 
h7 SetLineColor (kRed)
 
h9 SetLineColor (kBlue)
 
h11 SetMarkerColor (kRed)
 
h11 SetMarkerStyle (22)
 
c1 cd ()
 
h7 Draw ("HIST")
 
h8 Draw ("HIST SAME")
 
h10 Draw ("HIST P SAME")
 
xaxis SetTitle ("GeV")
 
xaxis Draw ()
 
gStyle SetOptStat (0)
 
leg AddEntry (h8,"to 2 gammas","l")
 
leg AddEntry (h7,"to MuPair","l")
 
leg AddEntry (h9,"to Hadrons","l")
 
h15 SetMinimum (minY1)
 
h15 SetMaximum (maxY1)
 
h15 SetTitle ("Comparison of EM Processes(totcrsPerVolume)")
 
h12 SetLineColor (6)
 
h13 SetLineColor (kGreen)
 
leg1 AddEntry (h15,"to 2 gammas","l")
 
leg1 AddEntry (h14,"to MuPair","l")
 
leg1 AddEntry (h16,"to Hadrons","l")
 
leg1 AddEntry (h12,"Bremsstrahlung","l")
 
leg1 AddEntry (h13,"Ionization","l")
 

Variables

double minE = 40
 
double maxE = 10000
 
double minY = 1e-2
 
double maxY = 1e+2
 
double minY1 = 1e-8
 
double maxY1 = 1
 
TH1D * h7 = (TH1D*)f.Get("h7")
 
TH1D * h8 = (TH1D*)f.Get("h8")
 
TH1D * h9 = (TH1D*)f.Get("h9")
 
TH1D * h10 = (TH1D*)f.Get("h10")
 
TH1D * h11 = (TH1D*)f.Get("h11")
 
TH1D * h12 = (TH1D*)f.Get("h12")
 
TH1D * h13 = (TH1D*)f.Get("h13")
 
TH1D * h14 = (TH1D*)f.Get("h14")
 
TH1D * h15 = (TH1D*)f.Get("h15")
 
TH1D * h16 = (TH1D*)f.Get("h16")
 
TH1D * h17 = (TH1D*)f.Get("h17")
 
TCanvas * c1 = new TCanvas("c1", " ")
 
TGaxis * xaxis = new TGaxis(std::log10(minE),minY,std::log10(maxE),minY,minE,maxE,510,"G")
 
TLegend * leg = new TLegend(0.78,0.59,0.98,0.76)
 
TCanvas * c2 = new TCanvas("c2", " ")
 
TGaxis * xaxis1 = new TGaxis(std::log10(minE),minY1,std::log10(maxE),minY1,minE,maxE,510,"G")
 
TLegend * leg1 = new TLegend(0.78,0.59,0.98,0.76)
 

Function Documentation

leg AddEntry ( h8  ,
"to 2 gammas"  ,
"l"   
)
leg AddEntry ( h7  ,
"to MuPair"  ,
"l"   
)
leg AddEntry ( h9  ,
"to Hadrons"  ,
"l"   
)
leg1 AddEntry ( h15  ,
"to 2 gammas"  ,
"l"   
)
leg1 AddEntry ( h14  ,
"to MuPair"  ,
"l"   
)
leg1 AddEntry ( h16  ,
"to Hadrons"  ,
"l"   
)
leg1 AddEntry ( h12  ,
"Bremsstrahlung"  ,
"l"   
)
leg1 AddEntry ( h13  ,
"Ionization"  ,
"l"   
)
c1 cd ( )
h7 Draw ( "HIST"  )
h8 Draw ( "HIST SAME"  )
h11 Draw ( "HIST P SAME"  )
xaxis Draw ( )
TFile f ( "testem6_0.root"  )
h7 GetXaxis ( ) -> SetLimits(std::log10(minE), std::log10(maxE))
h7 GetYaxis ( ) -> SetTitle("microbarn")
h7 SetLineColor ( kRed  )
h9 SetLineColor ( kBlue  )
h12 SetLineColor ( )
h13 SetLineColor ( kGreen  )
gPad SetLogy ( )
h11 SetMarkerColor ( kRed  )
h10 SetMarkerStyle ( 22  )
h7 SetMaximum ( maxY  )
h15 SetMaximum ( maxY1  )
h7 SetMinimum ( minY  )
h15 SetMinimum ( minY1  )
gStyle SetOptStat ( )
h7 SetTitle ( "Comparison of e+ Annihilation Processes(totcrsPerAtom)"  )
xaxis1 SetTitle ( "GeV"  )
h15 SetTitle ( "Comparison of EM Processes(totcrsPerVolume)"  )

Variable Documentation

TCanvas* c1 = new TCanvas("c1", " ")

Definition at line 38 of file plot_hist.C.

TH1D* h10 = (TH1D*)f.Get("h10")

Definition at line 23 of file plot_hist.C.

TH1D* h11 = (TH1D*)f.Get("h11")

Definition at line 24 of file plot_hist.C.

TH1D* h12 = (TH1D*)f.Get("h12")

Definition at line 27 of file plot_hist.C.

TH1D* h13 = (TH1D*)f.Get("h13")

Definition at line 28 of file plot_hist.C.

TH1D* h14 = (TH1D*)f.Get("h14")

Definition at line 29 of file plot_hist.C.

TH1D* h15 = (TH1D*)f.Get("h15")

Definition at line 30 of file plot_hist.C.

TH1D* h16 = (TH1D*)f.Get("h16")

Definition at line 31 of file plot_hist.C.

TH1D* h17 = (TH1D*)f.Get("h17")

Definition at line 34 of file plot_hist.C.

TH1D* h7 = (TH1D*)f.Get("h7")

Definition at line 20 of file plot_hist.C.

TH1D* h8 = (TH1D*)f.Get("h8")

Definition at line 21 of file plot_hist.C.

TH1D* h9 = (TH1D*)f.Get("h9")

Definition at line 22 of file plot_hist.C.

TLegend* leg = new TLegend(0.78,0.59,0.98,0.76)

Definition at line 67 of file plot_hist.C.

TLegend* leg1 = new TLegend(0.78,0.59,0.98,0.76)

Definition at line 105 of file plot_hist.C.

double maxY1 = 1

Definition at line 12 of file plot_hist.C.

double minE = 40

Definition at line 7 of file plot_hist.C.

double minY1 = 1e-8

Definition at line 11 of file plot_hist.C.

TGaxis* xaxis1 = new TGaxis(std::log10(minE),minY1,std::log10(maxE),minY1,minE,maxE,510,"G")

Definition at line 99 of file plot_hist.C.