1 #ifndef _theplu_yat_statistics_averagerpairweighted_
2 #define _theplu_yat_statistics_averagerpairweighted_
28 #include "AveragerWeighted.h"
30 #include "yat/utility/iterator_traits.h"
31 #include "yat/utility/yat_assert.h"
33 #include <boost/concept_check.hpp>
70 void add(
const double x,
const double y,
71 const double wx,
const double wy);
91 double msd(
void)
const;
106 double sum_w(
void)
const;
111 double sum_xy(
void)
const;
145 double wxy_centered_;
147 void xy_add(
double mx,
double my,
double xy_centered,
double w);
155 template <
class InputIterator1,
class InputIterator2>
157 InputIterator1 last1, InputIterator2 first2)
159 BOOST_CONCEPT_ASSERT((boost::InputIterator<InputIterator1>));
160 BOOST_CONCEPT_ASSERT((boost::InputIterator<InputIterator2>));
163 for ( ; first1 != last1; ++first1, ++first2) {
177 template <
typename InputIterator1,
typename InputIterator2
178 ,
typename InputIterator3,
typename InputIterator4>
180 InputIterator2 y, InputIterator3 wx, InputIterator4 wy)
182 BOOST_CONCEPT_ASSERT((boost::InputIterator<InputIterator1>));
183 BOOST_CONCEPT_ASSERT((boost::InputIterator<InputIterator2>));
184 BOOST_CONCEPT_ASSERT((boost::InputIterator<InputIterator3>));
185 BOOST_CONCEPT_ASSERT((boost::InputIterator<InputIterator4>));
191 ap.
add(*x, *y, *wx, *wy);