| 197 | } |
| 198 | |
| 199 | double |
| 200 | StatisticalTimer::getMean( sTimerID id ) const |
| 201 | { |
| 202 | if( clkTicks.empty( ) ) |
| 203 | return 0; |
| 204 | |
| 205 | size_t N = clkTicks.at( id ).size( ); |
| 206 | |
| 207 | Accumulator<unsigned long long> sum = std::for_each( clkTicks.at( id ).begin(), clkTicks.at( id ).end(), Accumulator<unsigned long long>() ); |
| 208 | |
| 209 | return static_cast<double>( sum.acc ) / N; |
| 210 | } |
| 211 | |
| 212 | double |
| 213 | StatisticalTimer::getVariance( sTimerID id ) const |
no test coverage detected