Changeset 7777 for trunk/MagicSoft/Mars/mhflux
- Timestamp:
- 07/05/06 11:41:13 (18 years ago)
- Location:
- trunk/MagicSoft/Mars/mhflux
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mhflux/MAlphaFitter.cc
r7741 r7777 330 330 // Assuming that bg and fit2.GetEventsBackground() are rather identical: 331 331 const Double_t sc = er*er / fit.GetEventsBackground(); 332 /* 332 333 333 cout << MMath::SignificanceLiMaSigned(hon.Integral(1, bin), fit.GetEventsBackground()/sc, sc) << " "; 334 334 cout << sc << " "; 335 335 cout << fit.fChiSqBg << endl; 336 */ 336 337 337 return sc; 338 338 } … … 404 404 } 405 405 406 void MAlphaFitter::PaintResult(Float_t x, Float_t y, Float_t size ) const406 void MAlphaFitter::PaintResult(Float_t x, Float_t y, Float_t size, Bool_t draw) const 407 407 { 408 408 const Double_t w = GetGausSigma(); … … 413 413 const TString fmt = Form("\\sigma_{L/M}=%%.1f \\omega=%%.%df\\circ E=%%d B=%%d x<%%.%df \\tilde\\chi_{b}=%%.1f \\tilde\\chi_{s}=%%.1f c=%%.1f f=%%.2f", 414 414 l1<1?1:l1+1, l2<1?1:l2+1); 415 416 TLatex text(x, y, Form(fmt.Data(), fSignificance, w, (int)fEventsExcess, 417 (int)fEventsBackground, m, fChiSqBg, fChiSqSignal, 418 fCoefficients[3], fScaleFactor)); 419 415 const TString txt = Form(fmt.Data(), fSignificance, w, (int)fEventsExcess, 416 (int)fEventsBackground, m, fChiSqBg, fChiSqSignal, 417 fCoefficients[3], fScaleFactor); 418 419 // This is totaly weired but the only way to get both options 420 // working with this nonsense implementation of TLatex 421 TLatex text(x, y, txt); 420 422 text.SetBit(TLatex::kTextNDC); 421 423 text.SetTextSize(size); 422 text.Paint(); 424 if (draw) 425 text.DrawLatex(x, y, txt); 426 else 427 text.Paint(); 423 428 424 429 TLine line; 425 430 line.SetLineColor(14); 426 line.PaintLine(m, gPad->GetUymin(), m, gPad->GetUymax()); 431 if (draw) 432 line.DrawLine(m, gPad->GetUymin(), m, gPad->GetUymax()); 433 else 434 line.PaintLine(m, gPad->GetUymin(), m, gPad->GetUymax()); 427 435 } 428 436 -
trunk/MagicSoft/Mars/mhflux/MAlphaFitter.h
r7720 r7777 237 237 238 238 // Interface to result 239 void PaintResult(Float_t x=0.04, Float_t y=0.94, Float_t size=0.035) const; 239 void PaintResult(Float_t x=0.04, Float_t y=0.94, Float_t size=0.035, Bool_t draw=kFALSE) const; 240 void DrawResult(Float_t x=0.04, Float_t y=0.94, Float_t size=0.035) const { PaintResult(x, y, size, kTRUE); } 240 241 241 242 // MTask
Note:
See TracChangeset
for help on using the changeset viewer.