Exemplo n.º 1
0
Arquivo: main.cpp Projeto: CCJY/coliru
int main()
    {
        RunningStat rs;

        rs.Push(17.0);
        rs.Push(19.0);
        rs.Push(24.0);

        double mean = rs.Mean();
        double variance = rs.Variance();
        double stdev = rs.StandardDeviation();
        
        cout << "mean = " << mean << endl;
        cout << "variance = " << variance << endl;
        cout << "stdev = " << stdev << endl;
    }
Exemplo n.º 2
0
void VideoCodecStatistics::Dump(RunningStat& s, const char *name)
{
  CSFLogDebug(logTag,
              "%s, mean: %f, variance: %f, standard deviation: %f",
              name, s.Mean(), s.Variance(), s.StandardDeviation());
}