sorry..I didn't realized that it was missing the following.
#include <boost/accumulators/statistics/variates/covariate.hpp>
Apologizes for my rush.


On Thu, Jun 3, 2010 at 11:10 AM, Conoscenza Silente <abruzzoforteegentile@gmail.com> wrote:
Hi All
I cannot build the following sample using accumulators.
Do you know why?
I used times ago an example and it worked without any problem.
Can you help me with that?

I have the following error
error: ‘covariate1’ was not declared in this scope

#include <iostream>
#include <boost/accumulators/accumulators.hpp>
#include <boost/accumulators/statistics/stats.hpp>
#include <boost/accumulators/statistics/mean.hpp>
#include <boost/accumulators/statistics/moment.hpp>
#include <boost/accumulators/statistics/variance.hpp>
#include <boost/accumulators/statistics/covariance.hpp>

using namespace boost::accumulators;

int main()
{
    accumulator_set<double, stats<tag::mean, tag::variance,    tag::covariance<double, tag::covariate1> > > x_acc;
    x_acc( 1.1, covariate1 = 2.2 ) ;     
    return 0;
}