Changeset 8281 for trunk/MagicSoft/Mars/mhvstime
- Timestamp:
- 02/01/07 11:24:19 (18 years ago)
- Location:
- trunk/MagicSoft/Mars/mhvstime
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mhvstime/MHSectorVsTime.cc
r8022 r8281 1 1 /* ======================================================================== *\ 2 ! $Name: not supported by cvs2svn $:$Id: MHSectorVsTime.cc,v 1.13 2007-02-01 11:24:19 tbretz Exp $ 3 ! -------------------------------------------------------------------------- 2 4 ! 3 5 ! * … … 18 20 ! Author(s): Thomas Bretz, 3/2004 <mailto:tbretz@astro.uni-wuerzburg.de> 19 21 ! 20 ! Copyright: MAGIC Software Development, 2000-200 422 ! Copyright: MAGIC Software Development, 2000-2006 21 23 ! 22 24 ! … … 70 72 // + Double_t fMaximum; // User defined maximum 71 73 // 74 // Class Version 3: 75 // ---------------- 76 // + Bool_t fUseMedian; 77 // 72 78 // 73 79 ///////////////////////////////////////////////////////////////////////////// … … 101 107 // 102 108 MHSectorVsTime::MHSectorVsTime(const char *name, const char *title) 103 : fGraph(0), fEvt(NULL), fMinimum(-1111), fMaximum(-1111), 109 : fGraph(0), fEvt(NULL), fMinimum(-1111), fMaximum(-1111), fUseMedian(kFALSE), 104 110 fType(0), fTypeErr(-1) 105 111 { … … 226 232 fHCamera.SetCamContent(*evt, fType); 227 233 228 const Double_t val0 = fHCamera.GetMeanSectors(fSectors, fAreaIndex); 234 const Double_t val0 = fUseMedian ? 235 fHCamera.GetMedianSectors(fSectors, fAreaIndex) : 236 fHCamera.GetMeanSectors(fSectors, fAreaIndex); 229 237 230 238 if (!TMath::Finite(val0)) … … 235 243 if (fTypeErr>=0) 236 244 { 237 const Double_t rms0 = fHCamera.GetRmsSectors(fSectors, fAreaIndex); 245 const Double_t rms0 = fUseMedian ? 246 fHCamera.GetDevSectors(fSectors, fAreaIndex) : 247 248 fHCamera.GetRmsSectors(fSectors, fAreaIndex); 238 249 if (!TMath::Finite(rms0)) 239 250 return kTRUE; 251 240 252 ((TGraphErrors*)fGraph)->SetPointError(fGraph->GetN()-1, 0, rms0); 241 253 } … … 334 346 TVirtualPad *pad = gPad ? gPad : MakeDefCanvas(fGraph); 335 347 pad->SetBorderMode(0); 348 pad->SetGridx(); 349 pad->SetGridy(); 336 350 AppendPad(opt); 337 351 } -
trunk/MagicSoft/Mars/mhvstime/MHSectorVsTime.h
r7358 r8281 1 /* ======================================================================== *\ 2 ! $Name: not supported by cvs2svn $:$Id: MHSectorVsTime.h,v 1.7 2007-02-01 11:24:19 tbretz Exp $ 3 \* ======================================================================== */ 1 4 #ifndef MARS_MHSectorVsTime 2 5 #define MARS_MHSectorVsTime … … 25 28 26 29 private: 27 TGraph *fGraph; 30 TGraph *fGraph; // The TGraph output to the display 28 31 29 MCamEvent *fEvt; //! the current event30 MGeomCam *fCam; //! the camera geometry32 MCamEvent *fEvt; //! pointer to the current event 33 MGeomCam *fCam; //! pointer the camera geometry 31 34 32 MRawEvtHeader *fHeader; //! 33 MTime *fTime; //! 35 MRawEvtHeader *fHeader; //! pointer to the event header (DAQ Evt number instead of counter) 36 MTime *fTime; //! pointer to event time (time instead of number) 34 37 35 MHCamera fHCamera; //! 38 MHCamera fHCamera; //! The camera to be used for calculation 36 39 37 40 Double_t fMin; //! Calculation of minimum … … 41 44 Double_t fMaximum; // User defined maximum 42 45 43 TString fNameEvt; 44 TString fNameTime; 46 Bool_t fUseMedian; // Whether to display median/dev instead of mean/rms 45 47 46 Int_t fType;47 Int_t fTypeErr;48 TString fNameEvt; // Name of MCamEvent to be displayed 49 TString fNameTime; // Name of MTime container to be used 48 50 49 TArrayI fSectors; 50 TArrayI fAreaIndex; 51 Int_t fType; // Type for mean used in GetPixelContent 52 Int_t fTypeErr; // Type for error used in GetPixelContent (-1 = no error) 53 54 TArrayI fSectors; // Which sectors shell be displayed 55 TArrayI fAreaIndex; // Which pixel sized should be displayed 51 56 52 57 // MH … … 69 74 void SetMaximum(Double_t max=-1111) { fMaximum = max; } 70 75 76 void SetUseMedian(Bool_t b=kTRUE) { fUseMedian=b; } 77 71 78 // Getter 72 79 TH1 *GetHistByName(const TString name="") const; … … 80 87 void Paint(Option_t *o=NULL); 81 88 82 ClassDef(MHSectorVsTime, 2) // Histogram to sum camera events89 ClassDef(MHSectorVsTime, 3) // Histogram to sum camera events 83 90 }; 84 91
Note:
See TracChangeset
for help on using the changeset viewer.