Changeset 8938 for trunk/MagicSoft/Mars/mhflux
- Timestamp:
- 06/12/08 14:00:47 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mhflux/MHEnergyEst.cc
r8935 r8938 317 317 { 318 318 pad->GetPad(1)->GetPad(2)->cd(1); 319 if ( (hx=(TH1D*)gPad->FindObject("EnergyEst_ez")))319 if (gPad->FindObject("EnergyEst_ez")) 320 320 fHEnergy.Project3D("ez"); 321 321 322 322 pad->GetPad(1)->GetPad(2)->cd(2); 323 hx = (TH1D*)fHResolutionEst.ProjectionY("Resolution", -1, -1, "e"); 324 TPaveStats *stats = dynamic_cast<TPaveStats*>(hx->FindObject("stats")); 325 if (stats) 323 if (gPad->FindObject("ResEnergyEst_py")) 326 324 { 327 stats->SetBit(BIT(17)); // TStyle.cxx: kTakeStyle=BIT(17) 328 stats->SetX1NDC(0.63); 329 stats->SetY1NDC(0.68); 325 hx = (TH1D*)fHResolutionEst.ProjectionY("_py", -1, -1, "e"); 326 TPaveStats *stats = dynamic_cast<TPaveStats*>(hx->FindObject("stats")); 327 if (stats) 328 { 329 stats->SetBit(BIT(17)); // TStyle.cxx: kTakeStyle=BIT(17) 330 stats->SetX1NDC(0.63); 331 stats->SetY1NDC(0.68); 332 } 333 334 hx->Fit("gaus", "Q", "", -1.0, 0.25); 335 hx->GetFunction("gaus")->SetLineColor(kBlue); 336 hx->GetFunction("gaus")->SetLineWidth(2); 337 gPad=NULL; 338 gStyle->SetOptFit(101); 330 339 } 331 332 hx->Fit("gaus", "Q", "", -1.0, 0.25);333 hx->GetFunction("gaus")->SetLineColor(kBlue);334 hx->GetFunction("gaus")->SetLineWidth(2);335 gPad=NULL;336 gStyle->SetOptFit(101);337 340 } 338 341 }
Note:
See TracChangeset
for help on using the changeset viewer.