27 , fFlagChannelActive(true)
28 , fHistUncertaintyBandExpectation(0)
29 , fHistUncertaintyBandPoisson(0)
59 if ( (filename.find_last_of(
".") != std::string::npos) &&
60 (filename.substr(filename.find_last_of(
".")+1) ==
"pdf") ) {
64 else if ( (filename.find_last_of(
".") != std::string::npos) &&
65 (filename.substr(filename.find_last_of(
".")+1) ==
"ps") ) {
74 TCanvas * c1 =
new TCanvas();
84 for (
int i = 0; i < ntemplates; ++i) {
88 if (first_hist < 0 && temphist)
96 if ( first_hist < 0 ) {
104 for (
int i = 0; i < ntemplates; ++i) {
109 TLatex* l =
new TLatex();
118 if (i == first_hist && (first_hist != last_hist))
119 c1->Print(std::string( filename +
"(").c_str());
120 else if (i == last_hist && (first_hist != last_hist))
121 c1->Print(std::string( filename +
")").c_str());
124 c1->Print(filename.c_str());
139 TCanvas * c1 =
new TCanvas();
149 if (nsystematics == 0)
152 c1->Print( (std::string(filename)+std::string(
"(")).c_str() );
155 for (
unsigned int isystematic = 0; isystematic < nsystematics; ++isystematic) {
164 TH1D hist = TH1D(*
GetTemplate(index)->GetHistogram());
166 TH1D hist_down(hist);
169 hist.SetFillStyle(0);
170 hist_up.SetFillStyle(0);
171 hist_up.SetLineStyle(2);
172 hist_down.SetFillStyle(0);
173 hist_down.SetLineStyle(3);
179 hist.Scale(efficiency/ hist.Integral());
182 for (
int i = 1; i <= hist.GetNbinsX(); ++i) {
183 hist.SetBinContent(i,
GetTemplate(index)->GetHistogram()->GetBinContent(i));
189 hist_up.Draw(
"HIST");
190 hist.Draw(
"HISTSAME");
191 hist_down.Draw(
"HISTSAME");
193 if (isystematic < nsystematics-1)
196 c1->Print( (std::string(filename)+std::string(
")")).c_str() );
207 TCanvas * c1 =
new TCanvas();
230 for (
int ix = 1; ix <= nbinsx_poisson; ++ix) {
233 for (
int iy = 1; iy <= nbinsy_exp; ++iy) {
238 for (
int iy = 1; iy <= nbinsy_exp; ++iy) {
242 for (
int jbin = 1; jbin <= nbinsy_poisson; ++jbin) {
243 double p = TMath::Poisson(
double(jbin-1), expectation);
244 double bincontent = 0;
258 hist->SetMarkerSize(0);
259 hist->SetFillColor(color);
260 hist->SetFillStyle(1001);
266 for (
int ix = 1; ix <= nbinsx_poisson; ++ix) {
269 int limit_max = nbinsx_poisson-1;
272 for (
int jbin = 1; jbin <= nbinsy_poisson; ++jbin) {
277 if (sum_p > maximum && (sum_p - p) < maximum )
284 hist->SetBinContent(ix, 0.5*
double(ylimit_min+ylimit_max));
285 hist->SetBinError(ix, 0.5*
double(ylimit_max-ylimit_min));
295 TCanvas * c1 =
new TCanvas();
303 int nbinsx_poisson = hist.GetNbinsX();
304 int nbinsy_poisson = hist.GetNbinsY();
307 for (
int ix = 1; ix <= nbinsx_poisson; ++ix) {
311 for (
int jbin = 1; jbin <= nbinsy_poisson; ++jbin) {
312 double p = hist.GetBinContent(ix, jbin);
314 hist.SetBinContent(ix, jbin, sum_p);
333 TCanvas * c1 =
new TCanvas();
354 TCanvas * c1 =
new TCanvas();