Changeset 2970
- Timestamp:
- 01/30/04 10:12:43 (21 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r2969 r2970 12 12 - modified GetPixelContent 13 13 14 * manalysis/MPedestalCam.cc 15 * manalysis/MPedCalcPedRun.cc 16 - include storage of number of used FADC slices to compare later 17 the pedestal per slice ( and sigma per slice_ 14 18 15 19 2004/01/29: Abelardo Moralejo -
trunk/MagicSoft/Mars/manalysis/MPedestalCam.cc
r2951 r2970 48 48 // Default constructor. Creates a MPedestalPix object for each pixel 49 49 // 50 MPedestalCam::MPedestalCam(const char *name, const char *title) 50 MPedestalCam::MPedestalCam(const char *name, const char *title) 51 : fNumTotSlices(0), fNumExtractSlices(0), fUseHists(kFALSE) 51 52 { 52 53 fName = name ? name : "MPedestalCam"; … … 54 55 55 56 fArray = new TClonesArray("MPedestalPix", 1); 56 57 57 58 } 58 59 … … 108 109 { 109 110 fArray->ForEach(TObject, Clear)(); 111 112 fNumTotSlices = 0; 113 fNumExtractSlices = 0; 110 114 } 111 115 … … 113 117 { 114 118 fArray->ForEach(MPedestalPix, InitUseHists)(); 119 120 fUseHists = kTRUE; 115 121 } 116 122 … … 181 187 { 182 188 189 if (!(*this)[idx].IsValid()) 190 return kFALSE; 191 192 if (idx == 559) 193 return kFALSE; 194 195 const Float_t pederr = (*this)[idx].GetPedestalRms()/TMath::Sqrt((Float_t)fNumTotSlices); 196 const Float_t rmserr = (*this)[idx].GetPedestalRms()/TMath::Sqrt((Float_t)fNumTotSlices/2.); 197 198 const Float_t mean = (*this)[idx].GetMean() / (Float_t)fNumExtractSlices; 199 const Float_t meanerr = (*this)[idx].GetMeanErr() / (Float_t)fNumExtractSlices; 200 const Float_t sigma = (*this)[idx].GetSigma() / TMath::Sqrt((Float_t) fNumExtractSlices); 201 const Float_t sigmaerr = (*this)[idx].GetSigmaErr() / TMath::Sqrt((Float_t) fNumExtractSlices); 202 183 203 switch (type) 184 204 { 185 205 case 0: 186 if ((*this)[idx].IsValid()) 187 val = (*this)[idx].GetPedestal(); 188 else 189 return kFALSE; 206 val = (*this)[idx].GetPedestal(); 190 207 break; 191 208 case 1: 192 if ((*this)[idx].IsValid()) 193 val = (*this)[idx].GetPedestalRms(); 194 else 195 return kFALSE; 209 val = pederr; 196 210 break; 197 211 case 2: 198 // if ((*this)[idx].IsFitValid()) 199 val = (*this)[idx].GetMean(); 200 // else 201 // return kFALSE; 212 val = (*this)[idx].GetPedestalRms(); 202 213 break; 203 214 case 3: 204 // if ((*this)[idx].IsFitValid()) 205 val = (*this)[idx].GetMeanErr(); 206 // else 207 // return kFALSE; 215 val = rmserr; 208 216 break; 209 217 case 4: 210 218 // if ((*this)[idx].IsFitValid()) 211 val = (*this)[idx].GetSigma();219 val = mean; 212 220 // else 213 221 // return kFALSE; … … 215 223 case 5: 216 224 // if ((*this)[idx].IsFitValid()) 217 val = (*this)[idx].GetSigmaErr();225 val = meanerr; 218 226 // else 219 227 // return kFALSE; … … 221 229 case 6: 222 230 // if ((*this)[idx].IsFitValid()) 223 val = (*this)[idx].GetProb();231 val = sigma; 224 232 // else 225 233 // return kFALSE; … … 227 235 case 7: 228 236 // if ((*this)[idx].IsFitValid()) 229 val = ((*this)[idx].GetPedestal()-(*this)[idx].GetMean());237 val = sigmaerr; 230 238 // else 231 239 // return kFALSE; … … 233 241 case 8: 234 242 // if ((*this)[idx].IsFitValid()) 235 val = ((*this)[idx].GetPedestalRms()-(*this)[idx].GetSigma()); 236 // else 237 // return kFALSE; 243 val = (*this)[idx].GetProb(); 244 // else 245 // return kFALSE; 246 break; 247 case 9: 248 // if ((*this)[idx].IsFitValid()) 249 val = ((*this)[idx].GetPedestal()-mean); 250 // else 251 // return kFALSE; 252 break; 253 case 10: 254 val = TMath::Sqrt(pederr*pederr + meanerr*meanerr); 255 break; 256 case 11: 257 val = (*this)[idx].GetPedestalRms()-sigma; 258 break; 259 case 12: 260 val = TMath::Sqrt(rmserr*rmserr + sigmaerr*sigmaerr); 238 261 break; 239 262 default:
Note:
See TracChangeset
for help on using the changeset viewer.