Changeset 7287 for trunk/MagicSoft/Mars/mhflux/MHDisp.cc
- Timestamp:
- 08/16/05 15:38:01 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mhflux/MHDisp.cc
r7224 r7287 389 389 const TAxis &axey = *h2.GetYaxis(); 390 390 391 const Double_t rmax = fWobble ? axex.GetXmax()-0.4 : axex.GetXmax();391 const Double_t rmax = (fWobble ? axex.GetXmax()-0.4 : axex.GetXmax()) - axex.GetBinWidth(1); 392 392 393 393 for (int x=1; x<=axex.GetNbins(); x++) … … 571 571 //Profile(*h2, *h1, x0, y0); 572 572 573 // Replace with MAlphaFitter? 574 TF1 func("fcn", "gaus + [3]*x*x + [4]"); 575 func.SetLineWidth(1); 576 func.SetLineColor(kBlue); 577 578 func.SetParLimits(2, h2->GetBinWidth(1), 1.0); 579 580 func.SetParameter(0, h2->GetBinContent(1)); 581 func.FixParameter(1, 0); 582 func.SetParameter(2, 0.12); 583 if (fHistOff) 584 func.FixParameter(3, 0); 585 func.SetParameter(4, 0);//h2->GetBinContent(20)); 586 h2->Fit(&func, "IQ", "", 0, 1.0); 587 588 h2->SetTitle(Form("P=(%.2f\\circ/%.2f\\circ) \\omega=%.2f\\circ f=%.2f", x0, y0, func.GetParameter(2), TMath::Abs(scale))); 573 if (h2->GetEntries()>0) 574 { 575 // Replace with MAlphaFitter? 576 TF1 func("fcn", "gaus + [3]*x*x + [4]"); 577 func.SetLineWidth(1); 578 func.SetLineColor(kBlue); 579 580 func.SetParLimits(2, h2->GetBinWidth(1), 1.0); 581 582 func.SetParameter(0, h2->GetBinContent(1)); 583 func.FixParameter(1, 0); 584 func.SetParameter(2, 0.12); 585 if (fHistOff) 586 func.FixParameter(3, 0); 587 func.SetParameter(4, 0);//h2->GetBinContent(20)); 588 h2->Fit(&func, "IQ", "", 0, 1.0); 589 590 h2->SetTitle(Form("P=(%.2f\\circ/%.2f\\circ) \\omega=%.2f\\circ f=%.2f", x0, y0, func.GetParameter(2), TMath::Abs(scale))); 591 } 589 592 } 590 593 … … 623 626 624 627 if (fHistOff) 625 GetCatalog()->Draw(" whitemirror same *");628 GetCatalog()->Draw("mirror same *"); 626 629 627 630 // ----- Pad number 1 ----- … … 643 646 644 647 if (fHistOff) 645 GetCatalog()->Draw(" whitemirror same *");648 GetCatalog()->Draw("mirror same *"); 646 649 647 650 // ----- Pad number 2 -----
Note:
See TracChangeset
for help on using the changeset viewer.