150 if (
num->GetXaxis()->GetXbins()->GetSize() == 0 &&
num->GetYaxis()->GetXbins()->GetSize() == 0) {
151 eff =
new TProfile2D(effName.c_str(),
153 num->GetXaxis()->GetNbins(),
154 num->GetXaxis()->GetXmin(),
155 num->GetXaxis()->GetXmax(),
156 num->GetYaxis()->GetNbins(),
157 num->GetYaxis()->GetXmin(),
158 num->GetYaxis()->GetXmax());
159 }
else if (
num->GetXaxis()->GetXbins()->GetSize() != 0 &&
num->GetYaxis()->GetXbins()->GetSize() == 0) {
160 eff =
new TProfile2D(effName.c_str(),
162 num->GetXaxis()->GetNbins(),
163 num->GetXaxis()->GetXbins()->GetArray(),
164 num->GetYaxis()->GetNbins(),
165 num->GetYaxis()->GetXmin(),
166 num->GetYaxis()->GetXmax());
167 }
else if (
num->GetXaxis()->GetXbins()->GetSize() == 0 &&
num->GetYaxis()->GetXbins()->GetSize() != 0) {
168 eff =
new TProfile2D(effName.c_str(),
170 num->GetXaxis()->GetNbins(),
171 num->GetXaxis()->GetXmin(),
172 num->GetXaxis()->GetXmax(),
173 num->GetYaxis()->GetNbins(),
174 num->GetYaxis()->GetXbins()->GetArray());
176 eff =
new TProfile2D(effName.c_str(),
178 num->GetXaxis()->GetNbins(),
179 num->GetXaxis()->GetXbins()->GetArray(),
180 num->GetYaxis()->GetNbins(),
181 num->GetYaxis()->GetXbins()->GetArray());
183 eff->SetTitle(effName.c_str());
184 eff->SetXTitle(
num->GetXaxis()->GetTitle());
185 eff->SetYTitle(
num->GetYaxis()->GetTitle());
186 eff->SetZTitle(
"Efficiency");
187 eff->SetOption(
"colztexte");
188 eff->GetZaxis()->SetRangeUser(-0.001, 1.001);
189 eff->SetStats(kFALSE);
190 for (
int i = 0;
i <
num->GetSize();
i++) {
192 if (
int(den->GetBinContent(
i)) > 0.)
193 e = double(
num->GetBinContent(
i)) /
double(den->GetBinContent(
i));
196 low = TEfficiency::Wilson((
double)den->GetBinContent(
i), (double)
num->GetBinContent(
i), 0.683,
false);
197 high = TEfficiency::Wilson((
double)den->GetBinContent(
i), (double)
num->GetBinContent(
i), 0.683,
true);
201 eff->SetBinContent(
i,
e);
202 eff->SetBinEntries(
i, 1);