Ignore:
Timestamp:
07/13/05 19:06:26 (19 years ago)
Author:
tbretz
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mhcalib/MHGausEvents.cc

    r6800 r7188  
    483483  option.ToLower();
    484484 
    485   Int_t win = 1;
     485  Int_t win   = 1;
    486486  Int_t nofit = 0;
    487487
    488488  if (option.Contains("events"))
    489     {
    490       option.ReplaceAll("events","");     
    491       win += 1;
    492     }
     489    win += 1;
    493490  if (option.Contains("fourier"))
    494     {
    495       option.ReplaceAll("fourier","");     
    496       win += 2;
    497     }
     491    win += 2;
    498492 
    499493  if (IsEmpty())
     
    779773}
    780774
    781 
    782 const Double_t MHGausEvents::GetChiSquare()  const
    783 {
    784   return ( fFGausFit ? fFGausFit->GetChisquare() : 0.);
    785 }
    786 
    787 
    788 const Double_t MHGausEvents::GetExpChiSquare()  const
    789 {
    790   return ( fFExpFit ? fFExpFit->GetChisquare() : 0.);
    791 }
    792 
    793 
    794 const Int_t MHGausEvents::GetExpNdf()  const
    795 {
    796   return ( fFExpFit ? fFExpFit->GetNDF() : 0);
    797 }
    798 
    799 
    800 const Double_t MHGausEvents::GetExpProb()  const
    801 {
    802   return ( fFExpFit ? fFExpFit->GetProb() : 0.);
    803 }
    804 
    805 
    806 const Int_t MHGausEvents::GetNdf() const
    807 {
    808   return ( fFGausFit ? fFGausFit->GetNDF() : 0);
    809 }
    810 
    811 const Double_t MHGausEvents::GetOffset()  const
    812 {
    813   return ( fFExpFit ? fFExpFit->GetParameter(0) : 0.);
    814 }
    815 
    816 
    817 
    818 // --------------------------------------------------------------------------
    819 //
    820 // If fFExpFit exists, returns fit parameter 1 (Slope of Exponential fit),
    821 // otherwise 0.
    822 //
    823 const Double_t MHGausEvents::GetSlope()  const
    824 {
    825   return ( fFExpFit ? fFExpFit->GetParameter(1) : 0.);
    826 }
    827 
    828775// --------------------------------------------------------------------------
    829776//
     
    839786  //  att.Copy(fHGausHist.GetXaxis());
    840787}
    841 
    842 // --------------------------------------------------------------------------
    843 //
    844 // Return kFALSE if number of entries is 0
    845 //
    846 const Bool_t MHGausEvents::IsEmpty() const
    847 {
    848   return !(fHGausHist.GetEntries());
    849 }
    850 
    851 // --------------------------------------------------------------------------
    852 //
    853 // Return kTRUE  if number of entries is bin content of fNbins+1
    854 //
    855 const Bool_t MHGausEvents::IsOnlyOverflow() const
    856 {
    857   return fHGausHist.GetEntries() == fHGausHist.GetBinContent(fNbins+1);
    858 }
    859 
    860 // --------------------------------------------------------------------------
    861 //
    862 // Return kTRUE  if number of entries is bin content of 0
    863 //
    864 const Bool_t MHGausEvents::IsOnlyUnderflow() const
    865 {
    866   return fHGausHist.GetEntries() == fHGausHist.GetBinContent(0);
    867 }
    868 
    869 
    870 const Bool_t MHGausEvents::IsExcluded() const
    871 {
    872   return TESTBIT(fFlags,kExcluded);
    873 }
    874 
    875 
    876 const Bool_t MHGausEvents::IsExpFitOK() const
    877 {
    878   return TESTBIT(fFlags,kExpFitOK);
    879 }
    880 
    881 const Bool_t MHGausEvents::IsFourierSpectrumOK() const
    882 {
    883   return TESTBIT(fFlags,kFourierSpectrumOK);
    884 }
    885 
    886 
    887 const Bool_t MHGausEvents::IsGausFitOK() const
    888 {
    889   return TESTBIT(fFlags,kGausFitOK);
    890 }
    891 
    892788
    893789// -----------------------------------------------------------------------------------
     
    929825}
    930826
    931 // --------------------------------------------------------------------------
    932 //
    933 // Set Excluded bit from outside
    934 //
    935 void MHGausEvents::SetExcluded(const Bool_t b)
    936 {
    937     b ? SETBIT(fFlags,kExcluded) : CLRBIT(fFlags,kExcluded);
    938 }
    939 
    940 
    941 // -------------------------------------------------------------------
    942 //
    943 // The flag setters are to be used ONLY for Monte-Carlo!!
    944 //
    945 void  MHGausEvents::SetExpFitOK(const Bool_t b)
    946 {
    947  
    948   b ? SETBIT(fFlags,kExpFitOK) : CLRBIT(fFlags,kExpFitOK); 
    949 }
    950 
    951 // -------------------------------------------------------------------
    952 //
    953 // The flag setters are to be used ONLY for Monte-Carlo!!
    954 //
    955 void  MHGausEvents::SetFourierSpectrumOK(const Bool_t b)
    956 {
    957 
    958   b ? SETBIT(fFlags,kFourierSpectrumOK) : CLRBIT(fFlags,kFourierSpectrumOK);   
    959 }
    960 
    961 
    962 // -------------------------------------------------------------------
    963 //
    964 // The flag setters are to be used ONLY for Monte-Carlo!!
    965 //
    966 void  MHGausEvents::SetGausFitOK(const Bool_t b)
    967 {
    968   b ? SETBIT(fFlags,kGausFitOK) : CLRBIT(fFlags,kGausFitOK);
    969 
    970 }
    971 
    972827// ----------------------------------------------------------------------------
    973828//
Note: See TracChangeset for help on using the changeset viewer.