Ignore:
Timestamp:
10/17/06 18:18:40 (18 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mhist
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mhist/MHCamera.cc

    r8022 r8106  
    11/* ======================================================================== *\
     2! $Name: not supported by cvs2svn $:$Id: MHCamera.cc,v 1.95 2006-10-17 17:16:00 tbretz Exp $
     3! --------------------------------------------------------------------------
    24!
    35! *
     
    361363// entries with match the given sector are taken into account.
    362364//
    363 Stat_t MHCamera::GetMeanSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t all) const
     365Stat_t MHCamera::GetMeanSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t ball) const
    364366{
    365367    if (fNcells<=1)
     
    371373    for (int i=0; i<fNcells-2; i++)
    372374    {
    373         if ((all || IsUsed(i)) && MatchSector(i, sector, aidx))
     375        if ((ball || IsUsed(i)) && MatchSector(i, sector, aidx))
    374376        {
    375377            if (TestBit(kProfile) && fBinEntries[i+1]==0)
     
    390392// entries with match the given sector are taken into account.
    391393//
    392 Stat_t MHCamera::GetRmsSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t all) const
     394Stat_t MHCamera::GetRmsSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t ball) const
    393395{
    394396    if (fNcells<=1)
     
    401403    for (int i=0; i<fNcells-2; i++)
    402404    {
    403         if ((all || IsUsed(i)) && MatchSector(i, sector, aidx))
     405        if ((ball || IsUsed(i)) && MatchSector(i, sector, aidx))
    404406        {
    405407            if (TestBit(kProfile) && fBinEntries[i+1]==0)
     
    429431// only pixels with matching sector number are taken into account.
    430432//
    431 Double_t MHCamera::GetMinimumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t all) const
     433Double_t MHCamera::GetMinimumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t ball) const
    432434{
    433435    if (fMinimum != -1111)
     
    445447
    446448        const Double_t val = TestBit(kProfile) ? fArray[i+1]/fBinEntries[i+1] : fArray[i+1];
    447         if (MatchSector(i, sector, aidx) && (all || IsUsed(i)) && val<minimum)
     449        if (MatchSector(i, sector, aidx) && (ball || IsUsed(i)) && val<minimum)
    448450            minimum = val;
    449451    }
     
    458460// only pixels with matching sector number are taken into account.
    459461//
    460 Double_t MHCamera::GetMaximumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t all) const
     462Double_t MHCamera::GetMaximumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t ball) const
    461463{
    462464    if (fMaximum!=-1111)
     
    473475
    474476        const Double_t val = TestBit(kProfile) ? fArray[i+1]/fBinEntries[i+1] : fArray[i+1];
    475         if (MatchSector(i, sector, aidx) && (all || IsUsed(i)) && val>maximum)
     477        if (MatchSector(i, sector, aidx) && (ball || IsUsed(i)) && val>maximum)
    476478            maximum = val;
    477479    }
  • trunk/MagicSoft/Mars/mhist/MHCamera.h

    r8066 r8106  
     1/* ======================================================================== *\
     2!  $Name: not supported by cvs2svn $:$Id: MHCamera.h,v 1.60 2006-10-17 17:16:00 tbretz Exp $
     3\* ======================================================================== */
    14#ifndef MARS_MHCamera
    25#define MARS_MHCamera
     
    172175    Stat_t   GetBinError(Int_t binx, Int_t biny, Int_t binz) const { return GetBinError(binx); }
    173176
    174     Double_t GetMinimum(Bool_t all) const { return GetMinimumSectors(TArrayI(), TArrayI(), all); }
    175     Double_t GetMaximum(Bool_t all) const { return GetMaximumSectors(TArrayI(), TArrayI(), all); }
     177    Double_t GetMinimum(Bool_t ball) const { return GetMinimumSectors(TArrayI(), TArrayI(), ball); }
     178    Double_t GetMaximum(Bool_t ball) const { return GetMaximumSectors(TArrayI(), TArrayI(), ball); }
    176179
    177180    Double_t GetMinimum(Double_t gt) const { return GetMinimumSectors(TArrayI(), TArrayI(), kFALSE); } // FIXME: To be done: Minimum greater than
     
    181184    Double_t GetMaximum() const { return GetMaximum(0.0); } // FIXME: To be done: Maximum lower than
    182185
    183     Double_t GetMinimumSector(Int_t sector, Int_t aidx, Bool_t all=kFALSE) const
    184     {
    185         return GetMinimumSectors(TArrayI(1, &sector), TArrayI(1, &aidx), all);
    186     }
    187     Double_t GetMaximumSector(Int_t sector, Int_t aidx, Bool_t all=kFALSE) const
    188     {
    189         return GetMaximumSectors(TArrayI(1, &sector), TArrayI(1, &aidx), all);
    190     }
    191     Double_t GetMinimumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t all=kFALSE) const;
    192     Double_t GetMaximumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t all=kFALSE) const;
     186    Double_t GetMinimumSector(Int_t sector, Int_t aidx, Bool_t ball=kFALSE) const
     187    {
     188        return GetMinimumSectors(TArrayI(1, &sector), TArrayI(1, &aidx), ball);
     189    }
     190    Double_t GetMaximumSector(Int_t sector, Int_t aidx, Bool_t ball=kFALSE) const
     191    {
     192        return GetMaximumSectors(TArrayI(1, &sector), TArrayI(1, &aidx), ball);
     193    }
     194    Double_t GetMinimumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t ball=kFALSE) const;
     195    Double_t GetMaximumSectors(const TArrayI &sector, const TArrayI &aidx, Bool_t ball=kFALSE) const;
    193196
    194197    void     SetLevels(const TArrayF &arr);
     
    236239    void     AddNotify(TObject *event);
    237240
    238     Stat_t   GetMean(Bool_t all) const { return GetMeanSectors(TArrayI(), TArrayI(), all); }
    239     Stat_t   GetRMS(Bool_t all)  const { return GetRmsSectors(TArrayI(), TArrayI(), all); }
     241    Stat_t   GetMean(Bool_t ball) const { return GetMeanSectors(TArrayI(), TArrayI(), ball); }
     242    Stat_t   GetRMS(Bool_t ball)  const { return GetRmsSectors(TArrayI(), TArrayI(), ball); }
    240243
    241244    Stat_t   GetMean(Int_t=0) const { return GetMeanSectors(TArrayI(), TArrayI(), kFALSE); }
     
    245248    Stat_t   GetMedianDev() const;
    246249
    247     Stat_t   GetMeanSector(Int_t sector, Int_t aidx, Bool_t all=kFALSE) const
    248     {
    249         return GetMeanSectors(TArrayI(1, &sector), TArrayI(1, &aidx), all);
    250     }
    251     Stat_t   GetRmsSector(Int_t sector, Int_t aidx, Bool_t all=kFALSE) const
    252     {
    253         return GetRmsSectors(TArrayI(1, &sector), TArrayI(1, &aidx), all);
     250    Stat_t   GetMeanSector(Int_t sector, Int_t aidx, Bool_t ball=kFALSE) const
     251    {
     252        return GetMeanSectors(TArrayI(1, &sector), TArrayI(1, &aidx), ball);
     253    }
     254    Stat_t   GetRmsSector(Int_t sector, Int_t aidx, Bool_t ball=kFALSE) const
     255    {
     256        return GetRmsSectors(TArrayI(1, &sector), TArrayI(1, &aidx), ball);
    254257    }
    255258
Note: See TracChangeset for help on using the changeset viewer.