AlcapDAQ  1
Functions | Variables
plot_mins.c File Reference

Go to the source code of this file.

Functions

gROOT SetStyle ("Plain")
 
gStyle SetOptStat (0)
 
gStyle SetOptFit (1111)
 
c1 Divide (4, 2)
 
 for (int i=1;i<=8;i++)
 

Variables

TCanvas * c1 = new TCanvas()
 

Function Documentation

c1 Divide ( ,
 
)
for ( int  i = 1; i <= 8; i++)

Definition at line 9 of file plot_mins.c.

References gROOT, i, and sprintf().

9  {
10  c1->cd(i);
11  TF1 *gaus = (TF1*)gROOT->GetFunction("gaus");
12  gaus->SetLineColor(kRed);
13  gaus->SetLineWidth(1);
14  sprintf(title, "py%d", i);
15 
16  TH1 *py = minSample->ProjectionY(title,i,i);
17  sprintf(title, "Channel %d", i-1);
18  py->SetTitle(title);
19  // py->GetXaxis()->SetRange(regions[i-1] - 2000, regions[i-1] + 2000);
20  // py->Draw("E1");
21  // py->Fit("gaus","LR","SAME",regions[i-1] - 2000, regions[i-1] + 2000);
22  Int_t x_min = 1000 ;
23  Int_t x_max = 2900 ;
24  py->Fit("gaus","","",x_min, x_max);
25  py->Draw("E1");
26  }
gStyle SetOptFit ( 1111  )
gStyle SetOptStat ( )
gROOT SetStyle ( "Plain"  )

Variable Documentation

TCanvas* c1 = new TCanvas()

Definition at line 6 of file plot_mins.c.