summaryrefslogtreecommitdiff
path: root/boost/accumulators/statistics/weighted_skewness.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/accumulators/statistics/weighted_skewness.hpp')
-rw-r--r--boost/accumulators/statistics/weighted_skewness.hpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/boost/accumulators/statistics/weighted_skewness.hpp b/boost/accumulators/statistics/weighted_skewness.hpp
index 6ccbc45ca1..a3ac3876f5 100644
--- a/boost/accumulators/statistics/weighted_skewness.hpp
+++ b/boost/accumulators/statistics/weighted_skewness.hpp
@@ -51,14 +51,14 @@ namespace impl
{
typedef typename numeric::functional::multiplies<Sample, Weight>::result_type weighted_sample;
// for boost::result_of
- typedef typename numeric::functional::average<weighted_sample, weighted_sample>::result_type result_type;
+ typedef typename numeric::functional::fdiv<weighted_sample, weighted_sample>::result_type result_type;
weighted_skewness_impl(dont_care) {}
template<typename Args>
result_type result(Args const &args) const
{
- return numeric::average(
+ return numeric::fdiv(
accumulators::weighted_moment<3>(args)
- 3. * accumulators::weighted_moment<2>(args) * weighted_mean(args)
+ 2. * weighted_mean(args) * weighted_mean(args) * weighted_mean(args)