Revision 0cbefdcc monl/result_buffer.cpp

View differences:

monl/result_buffer.cpp
122 122
	n_samples = 0; samples = 0; sum_samples = 0;
123 123
	sum_win_samples = 0; rate_sum_samples = 0;
124 124
	pos = 0;
125
	sum_var_samples = sum_win_var_samples = 0;
125
	sum_win_var_samples = 0;
126 126
	for(i = 0; i < LAST_STAT_TYPE; i++)
127 127
		stats[i] = (m->param_values[P_INIT_NAN_ZERO] == 0.0 ? NAN : 0);
128 128
	for(i = 0; i < size; i++)
......
180 180
	stats[AVG] = ((samples - 1) * stats[AVG] + r) / samples;
181 181

  
182 182
	/* Variance */
183
	sum_var_samples += pow(r - stats[AVG],2);
184

  
185 183
	if(samples < 2)
186 184
		stats[VAR] = 0;
187 185
	else

Also available in: Unified diff