src/c++/lib/statistics/NaiveGaussian.cpp
/**
 * Fit the observed data with a naive Gaussian (i.e. simple mean and variance)
 */
Fit the observed data with a naive Gaussian
Fit the observed data with a naive Gaussian
void NaiveGaussian::fit(const std::vector<double>& nums)
{
    std::pair<double, double> mean_var = statistics::basics::one_pass_mean_var(nums);
    mean(mean_var.first);
    variance(mean_var.second);
}
void NaiveGaussian :: fit ( const std :: vector < double > & nums ) { std :: pair < double , double > mean_var = statistics :: basics :: one_pass_mean_var ( nums ) ; mean ( mean_var . first ) ; variance ( mean_var . second ) ; }
Fit the observed data with a naive Gaussian (i.e.
Fit the observed data with a naive Gaussian ( i . e .