![]() |
Diana Software
|
Analyzes a list of values for the occurance of elements separated by regular intervals. More...
Public Member Functions | |
| QTimingAnalyzer () | |
| Constructor. More... | |
| virtual | ~QTimingAnalyzer () |
| Destructor. More... | |
| void | AddValue (const double value) |
| Add a time value to the list of values. More... | |
| void | ComputeGoodnessThreshold (const double falseRate) |
| Compute goodness threshold at given false positive rate. More... | |
| void | FindPeriod (const double uncertainty, const double stepSize=0.008) |
| Find period by searching within 'uncertainty' of fPeriod. More... | |
| unsigned int | GetBestGoodness () |
| Get best goodness parameter for the values in fValues. More... | |
| unsigned int | GetGoodness (const double value) |
| Get goodness for a given time, using adjustments. More... | |
| unsigned int | GetGoodnessParameter (const double value) |
| Get goodness for a given time value, no adjustments. More... | |
| unsigned int | GetGoodnessThreshold () const |
| Get goodness threshold at given false positive rate. More... | |
| double | GetPeriod () const |
| Get period. More... | |
| unsigned int | GetTotalGoodness () |
| Get total goodness for the values in fValues. More... | |
| void | SetAdjustments (const std::vector< double > &adjustments) |
| Set adjustments. More... | |
| void | SetExpectedPeriod (const double period) |
| Set period for repetition of values. More... | |
| void | SetTolerance (const double tolerance) |
| Set size of window in which to look for event. More... | |
Private Member Functions | |
| double | DistanceToClosestElement (const double value, double &closestValue) |
| Computes distance from 'value' to closest element in fValues. More... | |
Private Attributes | |
| std::vector< double > | fAdjustments |
| Adjustments. More... | |
| unsigned int | fGoodnessThreshold |
| Goodness threshold at a certain false positive rate. More... | |
| bool | fNeedsSort |
| Whether or not vector could be out of order. More... | |
| double | fPeriod |
| Period for repetition of values. More... | |
| double | fTolerance |
| Size of window in which to look for event. More... | |
| std::vector< double > | fValues |
| Time values. More... | |
Analyzes a list of values for the occurance of elements separated by regular intervals.
Definition at line 14 of file QTimingAnalyzer.hh.
| QTimingAnalyzer::QTimingAnalyzer | ( | ) |
Constructor.
Definition at line 21 of file QTimingAnalyzer.cc.
|
virtual |
Destructor.
Definition at line 26 of file QTimingAnalyzer.cc.
|
inline |
Add a time value to the list of values.
Definition at line 23 of file QTimingAnalyzer.hh.
References fNeedsSort, and fValues.
| void QTimingAnalyzer::ComputeGoodnessThreshold | ( | const double | falseRate | ) |
Compute goodness threshold at given false positive rate.
Definition at line 30 of file QTimingAnalyzer.cc.
References exp(), fAdjustments, fGoodnessThreshold, fPeriod, fTolerance, fValues, and pow().
Referenced by MPulserFlagByRegularTiming::Done().
|
private |
Computes distance from 'value' to closest element in fValues.
Definition at line 64 of file QTimingAnalyzer.cc.
References fNeedsSort, fValues, and min().
Referenced by GetGoodnessParameter().
| void QTimingAnalyzer::FindPeriod | ( | const double | uncertainty, |
| const double | stepSize = 0.008 |
||
| ) |
Find period by searching within 'uncertainty' of fPeriod.
Definition at line 104 of file QTimingAnalyzer.cc.
References fPeriod, and GetTotalGoodness().
Referenced by MPulserFlagByRegularTiming::Done().
| unsigned int QTimingAnalyzer::GetBestGoodness | ( | ) |
Get best goodness parameter for the values in fValues.
Definition at line 132 of file QTimingAnalyzer.cc.
References fValues, and GetGoodnessParameter().
| unsigned int QTimingAnalyzer::GetGoodness | ( | const double | value | ) |
Get goodness for a given time, using adjustments.
Definition at line 151 of file QTimingAnalyzer.cc.
References fAdjustments, and GetGoodnessParameter().
| unsigned int QTimingAnalyzer::GetGoodnessParameter | ( | const double | value | ) |
Get goodness for a given time value, no adjustments.
Definition at line 172 of file QTimingAnalyzer.cc.
References DistanceToClosestElement(), fPeriod, fTolerance, and fValues.
Referenced by GetBestGoodness(), GetGoodness(), and GetTotalGoodness().
|
inline |
Get goodness threshold at given false positive rate.
Definition at line 43 of file QTimingAnalyzer.hh.
References fGoodnessThreshold.
|
inline |
Get period.
Definition at line 46 of file QTimingAnalyzer.hh.
References fPeriod.
Referenced by MPulserFlagByRegularTiming::Done().
| unsigned int QTimingAnalyzer::GetTotalGoodness | ( | ) |
Get total goodness for the values in fValues.
Definition at line 208 of file QTimingAnalyzer.cc.
References fValues, and GetGoodnessParameter().
Referenced by FindPeriod().
|
inline |
Set adjustments.
Definition at line 52 of file QTimingAnalyzer.hh.
References fAdjustments.
Referenced by MPulserFlagByRegularTiming::Done().
|
inline |
Set period for repetition of values.
Definition at line 56 of file QTimingAnalyzer.hh.
References fPeriod.
Referenced by MPulserFlagByRegularTiming::Done().
|
inline |
Set size of window in which to look for event.
Definition at line 59 of file QTimingAnalyzer.hh.
References fTolerance.
Referenced by MPulserFlagByRegularTiming::Done().
|
private |
Adjustments.
Definition at line 68 of file QTimingAnalyzer.hh.
Referenced by ComputeGoodnessThreshold(), GetGoodness(), and SetAdjustments().
|
private |
Goodness threshold at a certain false positive rate.
Definition at line 71 of file QTimingAnalyzer.hh.
Referenced by ComputeGoodnessThreshold(), and GetGoodnessThreshold().
|
private |
Whether or not vector could be out of order.
Definition at line 74 of file QTimingAnalyzer.hh.
Referenced by AddValue(), and DistanceToClosestElement().
|
private |
Period for repetition of values.
Definition at line 77 of file QTimingAnalyzer.hh.
Referenced by ComputeGoodnessThreshold(), FindPeriod(), GetGoodnessParameter(), GetPeriod(), and SetExpectedPeriod().
|
private |
Size of window in which to look for event.
Definition at line 80 of file QTimingAnalyzer.hh.
Referenced by ComputeGoodnessThreshold(), GetGoodnessParameter(), and SetTolerance().
|
private |
Time values.
Definition at line 83 of file QTimingAnalyzer.hh.
Referenced by AddValue(), ComputeGoodnessThreshold(), DistanceToClosestElement(), GetBestGoodness(), GetGoodnessParameter(), and GetTotalGoodness().