Changeset 6985 for trunk/MagicSoft/Mars/manalysis
- Timestamp:
- 04/29/05 12:39:44 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/manalysis/MEventRateCalc.cc
r6455 r6985 155 155 Int_t MEventRateCalc::Process() 156 156 { 157 const ULong_t exec = GetNumExecutions()- 1;157 const ULong_t exec = GetNumExecutions()-fNumFirstEvent-1; 158 158 159 159 //*fLog << all << fNumFirstEvent << " " << exec << endl; … … 172 172 const UInt_t cnt = n1<n2 ? n : n1-n2; 173 173 174 if (cnt<n/10) 175 return kTRUE; 176 177 174 178 // Calculate the rate 175 179 const Double_t rate = (Double_t)cnt/(fTimes[n1%n]-fTimes[n2%n]); … … 190 194 fRate->SetRate(exec>1?rate:0, cnt); 191 195 fRate->SetReadyToSave(); 196 197 Double_t diff = fTimes[n1%n]- fTimes[n2%n]; 198 Double_t time = fTimes[n2%n]+ (cnt-n/10.)/(n-n/10.)*diff/2; 199 200 fTimeRate->SetMean(time, time); 201 202 //if (cnt>1000) 203 //*fLog << all << *fTimeRate << " " << *fTime << " " << diff << " " << cnt << " " << n << " " << (float)(cnt-n/2)/n << endl; 192 204 193 205 // Store the corresponding time
Note:
See TracChangeset
for help on using the changeset viewer.