Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r72885 - in sandbox/acc_ecdf: boost/accumulators/statistics/ecdf boost/accumulators/statistics/ecdf/aux_ libs/accumulators/ecdf/src libs/accumulators/ecdf/test libs/accumulators/ecdf/test/unit_test
From: erwann.rogard_at_[hidden]
Date: 2011-07-04 12:18:58


Author: e_r
Date: 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
New Revision: 72885
URL: http://svn.boost.org/trac/boost/changeset/72885

Log:
upd acc_ecdf
Text files modified:
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/check.hpp | 2
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/geometric_series_range.hpp | 108 -------------------------------
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/ignore.hpp | 2
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/incremental_simulator.hpp | 77 ----------------------
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_output.hpp | 98 ----------------------------
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_simulator.hpp | 70 --------------------
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cdf.hpp | 44 +++++++-----
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/count.hpp | 27 ++++---
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cumulative_count.hpp | 25 ++++---
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/kolmogorov_smirnov_statistic.hpp | 91 +++++++++++++++----------
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/ordered_sample.hpp | 22 +++---
   sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/pdf.hpp | 41 ++++++-----
   sandbox/acc_ecdf/libs/accumulators/ecdf/src/main.cpp | 16 +++-
   sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.cpp | 93 --------------------------
   sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.h | 12 ---
   sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.cpp | 137 ---------------------------------------
   sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.h | 24 ------
   sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/Jamfile.v2 | 11 --
   sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/ecdf.cpp | 20 -----
   19 files changed, 163 insertions(+), 757 deletions(-)

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/check.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/check.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/check.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 //////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/geometric_series_range.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/geometric_series_range.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/geometric_series_range.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,107 +1 @@
-//////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Use, modification and distribution are subject to the //
-// Boost Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-//////////////////////////////////////////////////////////////////////////////
-#ifndef BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_GEOMETRIC_SERIES_RANGE_ER_2011_HPP
-#define BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_GEOMETRIC_SERIES_RANGE_ER_2011_HPP
-#include <cstddef>
-#include <boost/accumulators/statistics/ecdf/aux_/ignore.hpp>
-#include <boost/iterator/counting_iterator.hpp>
-#include <boost/range/adaptor/transformed.hpp>
-#include <boost/range/iterator_range.hpp>
-
-namespace boost{
-//[syntax_ecdf_aux_geometric_series_range
-namespace accumulators{
-namespace ecdf{
-namespace aux_{
-
- template<typename N = std::size_t>
- struct geometric_series
- {
-
- geometric_series()/*<-*/
- :n_( 1 )
- , factor_( 2 )
- {}BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- geometric_series(N n, N factor)/*<-*/
- :n_( n )
- , factor_( factor )
- {}BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- typedef N result_type;
-
- template<typename T>
- N operator()(T const& anything)const/*<-*/
- {
- N m = this->n();
- this->n_ *= this->factor();
- return m;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- N const& n()const/*<-*/
- {
- return this->n_;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
- N const& factor()const/*<-*/
- {
- return this->factor_;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
-//<-
- private:
- mutable N n_;
- N factor_;
-//->
- };
-
-namespace result_of
-{
-
- template<typename N>
- struct geometric_series_iterator/*<-*/
- {
- typedef transform_iterator<
- geometric_series<N>,
- counting_iterator<N>
- > type;
- }/*->*/;
-
- template<typename N>
- struct geometric_series_range/*<-*/
- {
- typedef typename geometric_series_iterator<N>::type it_;
- typedef boost::iterator_range<it_> type;
- }/*->*/;
-
-}// result_of
-
- // n *= factor at each of size iterations
- template<typename N>
- typename result_of::geometric_series_range<N>::type
- geometric_series_range(N n, N factor, N size)/*<-*/
- {
- typedef geometric_series<N> geom_;
-
- return boost::adaptors::transform(
- boost::make_iterator_range(
- boost::counting_iterator<N>( 0 ),
- boost::counting_iterator<N>( size )
- ),
- geom_( n, factor )
- );
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
-}// aux_
-}// ecdf
-}// accumulators
-//]
-}// boost
-
-#endif // BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_GEOMETRIC_SERIES_RANGE_ER_2011_HPP
+// TODO remove file

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/ignore.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/ignore.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/ignore.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 //////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/incremental_simulator.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/incremental_simulator.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/incremental_simulator.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,76 +1 @@
-//////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Use, modification and distribution are subject to the //
-// Boost Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-//////////////////////////////////////////////////////////////////////////////
-#ifndef BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_INCREMENTAL_SIMULATOR_ER_2011_HPP
-#define BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_INCREMENTAL_SIMULATOR_ER_2011_HPP
-#include <cstddef>
-#include <boost/accumulators/statistics/ecdf/aux_/ignore.hpp>
-
-namespace boost{
-//[syntax_ecdf_aux_incremental_simulator
-namespace accumulators{
-namespace ecdf{
-namespace aux_{
-
- template<typename Gen, typename AccSet, typename Fun>
- class incremental_simulator
- {
-//<-
- typedef typename Gen::distribution_type dist_;
- typedef typename dist_::result_type sample_type;
-//->
- public:
-
- incremental_simulator(Gen gen, AccSet acc, Fun f)/*<-*/
- : gen_( gen ), acc_( acc ), fun_( f )
- {}BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- typedef typename Fun::result_type result_type;
-
- template<typename N>
- result_type operator()(N const& n)const/*<-*/
- {
- for( N i = 0; i < n; i++ )
- {
- sample_type x = this->gen_();
- this->acc_( x );
- } // increases sample size by n
-
- return this->fun_( this->accumulator() );
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- Gen const& gen()const/*<-*/
- {
- return this->gen_;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
- AccSet const& accumulator()const/*<-*/
- {
- return this->acc_;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
- Fun const& fun()const/*<-*/
- {
- return this->fun_;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
-//<-
- private:
- mutable Gen gen_;
- mutable AccSet acc_;
- Fun fun_;
-//->
- };
-
-}// aux_
-}// ecdf
-}// accumulators
-//]
-}// boost
-
-#endif // BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_INCREMENTAL_SIMULATOR_ER_2011_HPP
-
+// TODO remove file
\ No newline at end of file

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_output.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_output.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_output.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,97 +1 @@
-//////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Use, modification and distribution are subject to the //
-// Boost Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-//////////////////////////////////////////////////////////////////////////////
-#ifndef BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_KOLMOGOROV_SMIRNOV_OUTPUT_ER_2011_HPP
-#define BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_KOLMOGOROV_SMIRNOV_OUTPUT_ER_2011_HPP
-#include <boost/accumulators/statistics/count.hpp>
-#include <boost/accumulators/statistics/ecdf/aux_/ignore.hpp>
-#include <boost/accumulators/statistics/ecdf/kolmogorov_smirnov_statistic.hpp>
-#include <boost/format.hpp>
-#include <boost/numeric/conversion/bounds.hpp>
-
-namespace boost{
-//[syntax_ecdf_aux_kolmogorov_smirnov_output
-namespace accumulators{
-namespace ecdf{
-namespace aux_{
-
- // Template parameters:
- // D distribution
- // T value-type
- template<typename D, typename T = typename D::value_type>
- class kolmogorov_smirnov_output
- {
-//<-
- typedef boost::numeric::bounds<T> bounds_;
-//->
- public:
-
- typedef boost::format result_type;
- typedef T value_type;
-
- kolmogorov_smirnov_output(
- D dist
- , result_type custom_format = result_type( "(%1%, %2%)" )
- , value_type old_stat = bounds_::highest()
- )/*<-*/
- : d_( dist ),
- f_( custom_format ),
- old_stat_( old_stat )
- {}BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- result_type heading()const/*<-*/
- {
- return result_type( "(count, statistic, decreased)" );
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
-
- template<typename AccSet>
- result_type operator()( const AccSet& acc_set )const/*<-*/
- {
- namespace acc = accumulators;
- value_type new_stat = ecdf::kolmogorov_smirnov_statistic<
- value_type
- >( acc_set, this->distribution() );
-
- this->old_stat_ = new_stat;
- result_type result = this->f_;
- result
- % acc::extract::count( acc_set )
- % this->statistic();
- return result;
-
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- D const& distribution()const/*<-*/
- {
- return this->d_;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
- value_type const& statistic()const/*<-*/
- {
- return this->old_stat_;
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
-//<-
- private:
-
- D d_;
- result_type f_;
- mutable value_type old_stat_;
-//->
- };
-
-}// aux_
-}// ecdf
-}// accumulators
-//]
-}// boost
-
-#endif // BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_KOLMOGOROV_SMIRNOV_OUTPUT_ER_2011_HPP
-
+// TODO remove file
\ No newline at end of file

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_simulator.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_simulator.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_simulator.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,69 +1 @@
-//////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Use, modification and distribution are subject to the //
-// Boost Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-//////////////////////////////////////////////////////////////////////////////
-#ifndef BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_KOLMOGOROV_SMIRNOV_SIMULATOR_ER_2011_HPP
-#define BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_KOLMOGOROV_SMIRNOV_SIMULATOR_ER_2011_HPP
-#include <boost/accumulators/accumulators.hpp>
-#include <boost/accumulators/statistics/ecdf/aux_/ignore.hpp>
-#include <boost/accumulators/statistics/ecdf/aux_/incremental_simulator.hpp>
-#include <boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_output.hpp>
-#include <boost/accumulators/statistics/ecdf/kolmogorov_smirnov_statistic.hpp>
-#include <boost/accumulators/statistics_fwd.hpp>
-
-namespace boost{
-//[syntax_ecdf_aux_kolmogorov_smirnov_simulator
-namespace accumulators{
-namespace ecdf{
-namespace aux_{
-namespace result_of{
-
- template<typename Gen, typename D, typename T = typename D::value_type>
- struct kolmogorov_smirnov_simulator/*<-*/
- {
- typedef typename Gen::distribution_type random_;
- typedef typename random_::result_type sample_type;
-
- typedef ecdf::tag::kolmogorov_smirnov ks_tag_;
- typedef boost::accumulators::stats<ks_tag_> features_;
-
- typedef accumulators::accumulator_set<
- sample_type,
- features_
- > accumulator_set;
-
- typedef kolmogorov_smirnov_output<D, T> functor;
-
- typedef incremental_simulator<Gen, accumulator_set, functor> type;
-
- static type call(Gen gen, D dist)
- {
- accumulator_set set;
- functor f( dist );
- return type( gen, set, f );
- }
-
- }/*->*/;
-
-}// result_of
-
- template<typename Gen, typename D>
- typename result_of::kolmogorov_smirnov_simulator<Gen, D>::type
- kolmogorov_smirnov_simulator(Gen gen, D dist)/*<-*/
- {
- typedef result_of::kolmogorov_smirnov_simulator<Gen, D> caller_;
- return caller_::call( gen, dist );
- }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
-
-}// aux_
-}// ecdf
-}// accumulators
-//]
-}// boost
-
-#endif // BOOST_ACCUMULATORS_STATISTICS_ECDF_AUX_KOLMOGOROV_SMIRNOV_SIMULATOR_ER_2011_HPP
+// TODO remove file

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cdf.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cdf.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cdf.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //
@@ -25,8 +25,11 @@
 //<-
 namespace impl{
 
- // T can be an integer or a float
- template<typename T,typename T1,typename Comp = std::less<T> >
+ // Sample can be an integer or a float
+ template<
+ typename Sample, typename Result,
+ typename Comp = std::less<Sample>
+ >
     class cdf
         : public accumulator_base
     {
@@ -35,8 +38,8 @@
 
         public:
 
- typedef T1 result_type;
- typedef T sample_type;
+ typedef Result result_type;
+ typedef Sample sample_type;
 
         cdf(dont_care_){}
 
@@ -44,13 +47,12 @@
         
         template<typename Args>
         result_type result(const Args& args)const{
- namespace acc = boost::accumulators;
             typedef std::size_t size_;
             size_ i = extract::cumulative_count(
                 args[ accumulator ], args[ sample ]
             );
- size_ n = acc::extract::count( args[ accumulator ] );
- typedef numeric::converter<T1,size_> converter_;
+ size_ n = accumulators::extract::count( args[ accumulator ] );
+ typedef numeric::converter<Result,size_> converter_;
             return converter_::convert( i )/converter_::convert( n );
         }
 
@@ -60,7 +62,7 @@
 //->
 namespace tag
 {
- template<typename T1>
+ template<typename Result>
     struct cdf
         : depends_on<
             ecdf::tag::cumulative_count,
@@ -68,9 +70,9 @@
>
     {/*<-*/
         struct impl{
- template<typename T,typename W>
+ template<typename Sample, typename Weight>
             struct apply{
- typedef ecdf::impl::cdf<T,T1> type;
+ typedef ecdf::impl::cdf<Sample,Result> type;
             };
         };
     /*->*/};
@@ -78,29 +80,31 @@
 }// tag
 namespace result_of{
 
- template<typename T1,typename AccSet>
+ template<typename Result, typename AccumulatorSet>
     struct cdf/*<-*/
     {
- typedef ecdf::tag::cdf<T1> tag_;
+ typedef ecdf::tag::cdf<Result> tag_;
         typedef typename
             detail::template
- extractor_result<AccSet,tag_>::type type;
+ extractor_result<AccumulatorSet,tag_>::type type;
     }/*->*/;
 
 }// result_of
 namespace extract
 {
 
- template<typename T1,typename AccSet,typename T>
- typename ecdf::result_of::template cdf<T1,AccSet>::type
- cdf(AccSet const& set,const T& x)/*<-*/
+ template<typename Result, typename AccumulatorSet, typename Sample>
+ typename ecdf::result_of::template cdf<Result, AccumulatorSet>::type
+ cdf(AccumulatorSet const& set, const Sample& x)/*<-*/
     {
- namespace acc = boost::accumulators;
- typedef ecdf::tag::cdf<T1> tag_;
- return extract_result<tag_>( set, ( acc::sample = x ) );
+ typedef ecdf::tag::cdf<Result> tag_;
+ return extract_result<tag_>( set, ( accumulators::sample = x ) );
     }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
     
 }// extract
+
+ using extract::cdf;
+
 }// ecdf
 }// accumulators
 //]

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/count.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/count.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/count.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //
@@ -32,8 +32,8 @@
 //<-
 namespace impl{
 
- // T can be an integer or a float
- template<typename T>
+ // Sample can be an integer or a float
+ template<typename Sample>
     class count
         : public accumulator_base
     {
@@ -43,7 +43,7 @@
         public:
 
         typedef size_ result_type;
- typedef T sample_type;
+ typedef Sample sample_type;
 
         count(dont_care_){}
 
@@ -71,11 +71,11 @@
         : depends_on<
             ecdf::tag::ordered_sample
>
- /*<-*/{
+ {/*<-*/
         struct impl{
- template<typename T,typename W>
+ template<typename Sample, typename Weight>
             struct apply{
- typedef ecdf::impl::count<T> type;
+ typedef ecdf::impl::count<Sample> type;
             };
         };
     /*->*/};
@@ -83,27 +83,30 @@
 }// tag
 namespace result_of{
 
- template<typename AccSet,typename T>
+ template<typename AccumulatorSet, typename Sample>
     struct count/*<-*/
     {
         typedef ecdf::tag::count tag_;
         typedef typename detail::template
- extractor_result<AccSet,tag_>::type type;
+ extractor_result<AccumulatorSet,tag_>::type type;
     }/*->*/;
 
 }// result_of
 namespace extract
 {
 
- template<typename AccSet,typename T>
- typename ecdf::result_of::template count<AccSet,T>::type
- count(AccSet const& acc,const T& x)/*<-*/
+ template<typename AccumulatorSet, typename Sample>
+ typename ecdf::result_of::template count<AccumulatorSet,Sample>::type
+ count(AccumulatorSet const& acc, const Sample& x)/*<-*/
     {
         typedef ecdf::tag::count tag_;
         return extract_result<tag_>( acc, (sample = x) );
     }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
 
 }// extract
+
+ using extract::count;
+
 }// ecdf
 }// accumulators
 //]

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cumulative_count.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cumulative_count.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/cumulative_count.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //
@@ -26,8 +26,8 @@
 //<-
 namespace impl{
 
- // T can be an integer or a float
- template<typename T,typename Comp = std::less<T> >
+ // Sample can be an integer or a float
+ template<typename Sample, typename Comp = std::less<Sample> >
     class cumulative_count
         : public accumulator_base
     {
@@ -38,7 +38,7 @@
         public:
 
         typedef size_ result_type;
- typedef T sample_type;
+ typedef Sample sample_type;
 
         cumulative_count(dont_care_){}
 
@@ -102,9 +102,9 @@
>
     {/*<-*/
         struct impl{
- template<typename T,typename W>
+ template<typename Sample, typename Weight>
             struct apply{
- typedef ecdf::impl::cumulative_count<T> type;
+ typedef ecdf::impl::cumulative_count<Sample> type;
             };
         };
     /*->*/};
@@ -112,22 +112,22 @@
 }// tag
 namespace result_of{
 
- template<typename AccSet>
+ template<typename AccumulatorSet>
     struct cumulative_count/*<-*/
     {
         typedef ecdf::tag::cumulative_count tag_;
         typedef typename
             detail::template
- extractor_result<AccSet,tag_>::type type;
+ extractor_result<AccumulatorSet,tag_>::type type;
     }/*->*/;
 
 }// result_of
 namespace extract
 {
 
- template<typename AccSet,typename T>
- typename ecdf::result_of::template cumulative_count<AccSet>::type
- cumulative_count(AccSet const& acc,const T& x)/*<-*/
+ template<typename AccumulatorSet, typename Sample>
+ typename ecdf::result_of::template cumulative_count<AccumulatorSet>::type
+ cumulative_count(AccumulatorSet const& acc, const Sample& x)/*<-*/
     {
         typedef ecdf::tag::cumulative_count tag_;
         return extract_result<tag_>(
@@ -137,6 +137,9 @@
     }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
 
 }// extract
+
+ using extract::cumulative_count;
+
 }// ecdf
 }// accumulators
 //]

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/kolmogorov_smirnov_statistic.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/kolmogorov_smirnov_statistic.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/kolmogorov_smirnov_statistic.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //
@@ -8,6 +8,8 @@
 ///////////////////////////////////////////////////////////////////////////////
 #ifndef BOOST_ACCUMULATORS_STATISTICS_KOLMOGOROV_SMIRNOV_STATISTIC_HPP_ER_2011
 #define BOOST_ACCUMULATORS_STATISTICS_KOLMOGOROV_SMIRNOV_STATISTIC_HPP_ER_2011
+#include <cstddef>
+#include <cmath>
 #include <boost/accumulators/framework/extractor.hpp>
 #include <boost/accumulators/framework/accumulator_base.hpp>
 #include <boost/accumulators/framework/parameters/sample.hpp>
@@ -17,6 +19,7 @@
 #include <boost/accumulators/statistics/ecdf/aux_/ignore.hpp>
 #include <boost/accumulators/statistics/ecdf/count.hpp>
 #include <boost/accumulators/statistics/stats.hpp>
+#include <boost/numeric/conversion/converter.hpp>
 #include <boost/mpl/placeholders.hpp>
 #include <boost/mpl/apply.hpp>
 #include <boost/mpl/if.hpp>
@@ -32,7 +35,7 @@
 //<-
 namespace impl{
 
- template<typename T>
+ template<typename Sample>
     class kolmogorov_smirnov
         : public accumulator_base
     {
@@ -45,31 +48,31 @@
         kolmogorov_smirnov(dont_care_){};
 
         typedef size_ size_type;
- typedef T sample_type;
+ typedef Sample sample_type;
         typedef void result_type;
 
         void operator()(dont_care_)const{}
 
         template<typename Args>
         result_type result(dont_care_) const
- {
- }
+ {}
+
     };
     
 }// impl
 //->
 namespace tag
 {
- struct kolmogorov_smirnov
+ struct kolmogorov_smirnov_statistic
       : depends_on<
           ecdf::tag::ordered_sample,
           accumulators::tag::count
>
     {/*<-*/
         struct impl{
- template<typename T, typename W>
+ template<typename Sample, typename Weight>
             struct apply{
- typedef ecdf::impl::kolmogorov_smirnov<T> type;
+ typedef ecdf::impl::kolmogorov_smirnov<Sample> type;
             };
         };
     /*->*/};
@@ -77,53 +80,67 @@
 }// tag
 namespace result_of{
 
- template<typename T1,typename AccSet,typename D>
+ template<
+ typename AccumulatorSet, typename Distribution
+ , typename T = typename Distribution::value_type
+ >
     struct kolmogorov_smirnov_statistic/*<-*/
     {
- typedef T1 type;
+ typedef T type;
     }/*->*/;
 
 }// result_of
+namespace extract{
 
- // Usage : statistic<T1>(acc,dist)
- template<typename T1,typename AccSet,typename D>
+ template<typename Result, typename AccumulatorSet, typename Distribution>
     typename result_of::template
- kolmogorov_smirnov_statistic<T1, AccSet, D>::type
- kolmogorov_smirnov_statistic(AccSet const& set,const D& dist)/*<-*/
+ kolmogorov_smirnov_statistic<AccumulatorSet, Distribution, Result>::type
+ kolmogorov_smirnov_statistic(
+ AccumulatorSet const& acc,
+ const Distribution& dist
+ )/*<-*/
     {
- namespace acc = boost::accumulators;
-
- typedef T1 val_;
+ typedef Result result_;
             typedef std::size_t size_;
- typedef tag::count tag_n_;
- typedef ecdf::tag::ordered_sample tag_os_;
 
             typedef typename ecdf::result_of::ordered_sample<
- AccSet>::type ref_os_;
- typedef typename boost::remove_const< //in case ref changed to cref
+ AccumulatorSet
+ >::type result_ordered_sample_;
+
+ typedef typename boost::remove_const<
                 typename boost::remove_reference<
- ref_os_
+ result_ordered_sample_
>::type
- >::type os_;
- typedef typename boost::range_reference<os_>::type ref_elem_;
+ >::type ordered_sample_;
 
- ref_os_ ref_os = extract_result<tag_os_>( set );
-
- val_ m1 = static_cast<val_>(0);
+ typedef typename boost::range_reference<
+ ordered_sample_
+ >::type pair_;
+
+ typedef numeric::converter<size_, result_> converter_;
+ result_
+ result = converter_::convert( 0 ),
+ a, x, y,
+ n = converter_::convert( accumulators::count( acc ) );
             size_ i = 0;
- size_ n = acc::extract::count( set );
             
- BOOST_FOREACH(ref_elem_ e,ref_os){
- i += e.second;
- val_ ecdf_val = static_cast<val_>(i) / static_cast<val_>(n);
- val_ true_cdf = cdf( dist, e.first );
- val_ m2 = (true_cdf > ecdf_val )
- ?(true_cdf - ecdf_val) : (ecdf_val - true_cdf);
- if( m2 > m1 ){ m1 = m2; }
+ BOOST_FOREACH( pair_ p, ecdf::ordered_sample( acc ) )
+ {
+ i += p.second;
+ x = converter_::convert( i ) / n;
+ typedef typename Distribution::value_type val_;
+ y = numeric::converter<val_, result_>::convert(
+ cdf( dist, p.first )
+ );
+ a = fabs( x - y );
+ result = ( a > result ) ? a : result;
             }
-
- return m1;
+ return result;
     }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
+
+}// extract
+
+ using extract::kolmogorov_smirnov_statistic;
 
 }// ecdf
 }// accumulators

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/ordered_sample.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/ordered_sample.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/ordered_sample.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //
@@ -27,19 +27,19 @@
 //<-
 namespace impl{
 
- template<typename T>
+ template<typename Sample>
     class ordered_sample
         : public accumulator_base
     {
- typedef std::less<T> comp_;
+ typedef std::less<Sample> comp_;
         typedef std::size_t size_;
         typedef dont_care dont_care_;
- typedef std::map<T,size_,comp_> map_;
+ typedef std::map<Sample,size_,comp_> map_;
 
         public:
         
         // See accumulator_set for convention naming sample_type
- typedef T sample_type;
+ typedef Sample sample_type;
         typedef size_ size_type;
 
         // non-const because map::operator[](key) returns a non-const
@@ -51,7 +51,7 @@
         void operator()(const Args& args){
             ++(
                 this->freq[
- static_cast<T>(
+ static_cast<Sample>(
                         args[sample]
                     )
                 ]
@@ -82,10 +82,10 @@
 }// tag
 namespace result_of{
 
- template<typename AccSet>
+ template<typename AccumulatorSet>
     struct ordered_sample/*<-*/
         : detail::extractor_result<
- AccSet,
+ AccumulatorSet,
             ecdf::tag::ordered_sample
>
     {}/*->*/;
@@ -94,9 +94,9 @@
 namespace extract
 {
 
- template<typename AccSet>
- typename ecdf::result_of::template ordered_sample<AccSet>::type
- ordered_sample(AccSet const& acc)/*<-*/
+ template<typename AccumulatorSet>
+ typename ecdf::result_of::template ordered_sample<AccumulatorSet>::type
+ ordered_sample(AccumulatorSet const& acc)/*<-*/
     {
         typedef ecdf::tag::ordered_sample the_tag;
         return extract_result<the_tag>(acc);

Modified: sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/pdf.hpp
==============================================================================
--- sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/pdf.hpp (original)
+++ sandbox/acc_ecdf/boost/accumulators/statistics/ecdf/pdf.hpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
+// accumulator_ecdf //
 // //
 // Copyright (C) 2005 Eric Niebler //
 // Copyright (C) 2011 Erwann Rogard //
@@ -27,7 +27,7 @@
 namespace impl{
 
     // T can be an integer or a float
- template<typename T,typename T1>
+ template<typename Sample, typename Result>
     class pdf
         : public accumulator_base
     {
@@ -35,8 +35,8 @@
 
         public:
 
- typedef T1 result_type;
- typedef T sample_type;
+ typedef Result result_type;
+ typedef Sample sample_type;
 
         pdf(dont_care_){}
 
@@ -45,13 +45,12 @@
         template<typename Args>
         result_type result(const Args& args)const{
             typedef std::size_t size_;
- namespace acc = boost::accumulators;
             size_ i = ecdf::extract::count(
- args[ acc::accumulator ],
+ args[ accumulator ],
                 args[ sample ]
             );
- size_ n = acc::extract::count( args[ acc::accumulator ] );
- typedef numeric::converter<T1,size_> converter_;
+ size_ n = accumulators::extract::count( args[ accumulator ] );
+ typedef numeric::converter<Result,size_> converter_;
             return converter_::convert( i ) / converter_::convert( n );
         }
 
@@ -62,16 +61,16 @@
 namespace tag
 {
 
- template<typename T1>
+ template<typename Result>
     struct pdf: depends_on<
         ecdf::tag::count,
         accumulators::tag::count
>
     {/*<-*/
         struct impl{
- template<typename T,typename W>
+ template<typename Sample, typename Weight>
             struct apply{
- typedef ecdf::impl::pdf<T,T1> type;
+ typedef ecdf::impl::pdf<Sample, Result> type;
             };
         };
     /*->*/};
@@ -79,29 +78,31 @@
 }// tag
 namespace result_of{
 
- template<typename T1,typename AccSet>
+ template<typename Result, typename AccumulatorSet>
     struct pdf/*<-*/
     {
- typedef ecdf::tag::pdf<T1> tag_;
+ typedef ecdf::tag::pdf<Result> tag_;
         typedef typename
             detail::template
- extractor_result<AccSet,tag_>::type type;
+ extractor_result<AccumulatorSet,tag_>::type type;
     }/*->*/;
 
 }// result_of
 namespace extract
 {
 
- template<typename T1, typename AccSet, typename T>
- typename ecdf::result_of::template pdf<T1, AccSet>::type
- pdf(AccSet const& set, const T& x)/*<-*/
+ template<typename Result, typename AccumulatorSet, typename T>
+ typename ecdf::result_of::template pdf<Result, AccumulatorSet>::type
+ pdf(AccumulatorSet const& set, const T& x)/*<-*/
     {
- namespace acc = boost::accumulators;
- typedef ecdf::tag::pdf<T1> tag_;
- return extract_result<tag_>( set, ( acc::sample = x ) );
+ typedef ecdf::tag::pdf<Result> tag_;
+ return extract_result<tag_>( set, ( sample = x ) );
     }BOOST_ACCUMULATORS_ECDF_IGNORE(/*->*/;/*<-*/)/*->*/
 
 }// extract
+
+ using extract::pdf;
+
 }// ecdf
 }// accumulators
 //]

Modified: sandbox/acc_ecdf/libs/accumulators/ecdf/src/main.cpp
==============================================================================
--- sandbox/acc_ecdf/libs/accumulators/ecdf/src/main.cpp (original)
+++ sandbox/acc_ecdf/libs/accumulators/ecdf/src/main.cpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,11 +1,19 @@
 #include <iostream>
-#include <libs/accumulators/ecdf/test/ecdf.h>
-#include <libs/accumulators/ecdf/test/ks_sim.h>
+#include <libs/accumulators/ecdf/test/count.h>
+#include <libs/accumulators/ecdf/test/cumulative_count.h>
+#include <libs/accumulators/ecdf/test/pdf.h>
+#include <libs/accumulators/ecdf/test/cdf.h>
+#include <libs/accumulators/ecdf/test/kolmogorov_smirnov_statistic.h>
+#include <libs/accumulators/ecdf/test/ks_gen.h>
 
 int main()
 {
- test_ecdf();
- test_ks_sim(std::cout);
+ test_ecdf_count();
+ test_ecdf_cumulative_count();
+ test_ecdf_pdf();
+ test_ecdf_cdf();
+ test_ecdf_kolmogorov_smirnov_statistic();
+ test_ks_gen(std::cout);
 
     return 0;
 }
\ No newline at end of file

Modified: sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.cpp
==============================================================================
--- sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.cpp (original)
+++ sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.cpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,92 +1 @@
-///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-///////////////////////////////////////////////////////////////////////////////
-#include <cmath>
-#include <vector>
-#include <boost/mpl/int.hpp>
-#include <boost/accumulators/accumulators.hpp>
-#include <boost/accumulators/statistics/stats.hpp>
-#include <boost/accumulators/statistics/ecdf/aux_/check.hpp>
-#include <boost/accumulators/statistics/ecdf/ordered_sample.hpp>
-#include <boost/accumulators/statistics/ecdf/cumulative_count.hpp>
-#include <boost/accumulators/statistics/ecdf/pdf.hpp>
-#include <boost/accumulators/statistics/ecdf/cdf.hpp>
-#include <boost/format.hpp>
-#include <boost/numeric/conversion/bounds.hpp>
-#include <boost/numeric/conversion/bounds.hpp>
-#include <boost/range/algorithm/for_each.hpp>
-#include <libs/accumulators/ecdf/test/ecdf.h>
-
-void test_ecdf()
-{
-
-//[test_ecdf
- typedef int sample_; // sample_ x = 1;
- typedef double val_; // val_ p = pdf( dist, x );
- typedef std::vector<sample_> samples_;
-
- namespace acc = boost::accumulators;
- namespace num = boost::numeric;
-
- samples_ samples;
- const int n = 3;
- for(int i = 0; i < n; i++)
- {
- for(int j = i; j < n; j++)
- {
- samples.push_back( n-i );
- }
- }// 3, 3, 3, 2, 2, 1
-
- namespace ecdf = acc::ecdf;
- typedef ecdf::tag::cdf<val_> tag_cdf_;
- typedef ecdf::tag::count tag_pdf_;
- typedef acc::accumulator_set<
- sample_,
- acc::stats<tag_pdf_, tag_cdf_>
- > set_;
-
- set_ set = boost::for_each(
- samples,
- set_()
- );
-
- long sum = 0;
- val_ cum_freq;
- for(int i = 0; i < n; i++)
- {
-
- typedef num::converter<int,std::size_t> converter_;
- BOOST_ACCUMULATORS_ECDF_CHECK(
- (
- converter_::convert(
- ecdf::extract::count( set , i+1 )
- ) == i+1
- )
- );
-
- sum += i+1;
- BOOST_ACCUMULATORS_ECDF_CHECK(
- (
- converter_::convert(
- ecdf::extract::cumulative_count( set, i+1 )
- ) == sum
- )
- );
-
- cum_freq = ecdf::extract::cdf<val_>( set, i+1 );
-
- }
-
- val_ one = 1.0;
- typedef num::bounds<val_> bounds_;
- val_ eps = bounds_::smallest();
- BOOST_ACCUMULATORS_ECDF_CHECK( fabs(cum_freq - one) < eps );
-//]
-
-}
+// TODO remove file

Modified: sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.h
==============================================================================
--- sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.h (original)
+++ sandbox/acc_ecdf/libs/accumulators/ecdf/test/ecdf.h 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,11 +1 @@
-///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-///////////////////////////////////////////////////////////////////////////////
-
-
-void test_ecdf();
+// TODO remove file
\ No newline at end of file

Modified: sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.cpp
==============================================================================
--- sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.cpp (original)
+++ sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.cpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,136 +1 @@
-///////////////////////////////////////////////////////////////////////////////
-// kolmogorov_smirnov_statistic.cpp //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-///////////////////////////////////////////////////////////////////////////////
-#include <vector>
-#include <iterator>
-#include <string>
-#include <boost/accumulators/accumulators.hpp>
-#include <boost/accumulators/statistics/ecdf/aux_/geometric_series_range.hpp>
-#include <boost/accumulators/statistics/ecdf/aux_/kolmogorov_smirnov_simulator.hpp>
-#include <boost/accumulators/statistics/stats.hpp>
-#include <boost/format.hpp>
-#include <boost/foreach.hpp>
-#include <boost/mpl/int.hpp>
-#include <boost/math/distributions/normal.hpp>
-#include <boost/math/distributions/poisson.hpp>
-#include <boost/range/algorithm/transform.hpp>
-#include <boost/random/normal_distribution.hpp>
-#include <boost/random/mersenne_twister.hpp>
-#include <boost/random/poisson_distribution.hpp>
-#include <boost/random/variate_generator.hpp>
-#include <boost/typeof/typeof.hpp>
-
-#include <boost/range/algorithm/for_each.hpp>
-
-#include <libs/accumulators/ecdf/test/ks_sim.h>
-
-void test_ks_sim(
- std::ostream& os,
- double mean,
- long n,
- long factor,
- long size
-)
-{
-
-//[test_ks_sim
- const std::string str = "sample size vs kolmogorov smirnov statisic:";
-
- // A series of Kolmogorov-Smirnov statistics, computed over an iid
- // sample of increasing size (n). The reference distribution is that of
- // the random generator, so the series is expected to converge to zero.
- // Warning : numeric error may dominate for large n.
-
- namespace acc = boost::accumulators;
- namespace ecdf = acc::ecdf;
- namespace aux_ = ecdf::aux_;
- typedef boost::mt19937 urng_;
-
- urng_ urng;
-
- {
- typedef boost::math::poisson_distribution<> dist_;
- typedef dist_::value_type val_;
- typedef boost::poisson_distribution<> random_;
- typedef boost::variate_generator<urng_&,random_> vg_;
- dist_ dist( mean );
- vg_ vg( urng, random_(mean) );
-
- os << "poisson(" << mean << ')' << std::endl;
- boost::transform(
- aux_::geometric_series_range(n, factor, size),
- std::ostream_iterator<boost::format>( os, "\n" ),
- aux_::kolmogorov_smirnov_simulator( vg, dist )
- );
- os << std::endl;
-/* ouputs:
-poison(1)
-(1, 0.0803014)
-(3, 0.0803014)
-(7, 0.0821652)
-(15, 0.0987872)
-(31, 0.21963)
-(63, 0.148457)
-(127, 0.0979636)
-(255, 0.0612491)
-(511, 0.0136454)
-(1023, 0.00715412)
-(2047, 0.00534967)
-(4095, 0.00548628)
-(8191, 0.00858265)
-(16383, 0.00287263)
-(32767, 0.00364357)
-(65535, 0.00236578)
-(131071, 0.00147762)
-(262143, 0.000797197)
-(524287, 0.0005051)
-(1048575, 0.000203309)*/
-
- }
- {
- typedef boost::math::normal_distribution<> dist_;
- typedef dist_::value_type val_;
- typedef boost::normal_distribution<> random_;
- typedef boost::variate_generator<urng_&, random_> vg_;
- const val_ sd = 1.0;
- dist_ dist( mean, sd );
- vg_ vg( urng, random_(mean) );
-
- os << "normal(" << mean << ',' << sd << ')' << std::endl;
- boost::transform(
- aux_::geometric_series_range(n, factor, size),
- std::ostream_iterator<boost::format>( os, "\n" ),
- aux_::kolmogorov_smirnov_simulator( vg, dist )
- );
- os << std::endl;
-/*
-normal(1,1)
-(1, 0.514901)
-(3, 0.23449)
-(7, 0.177523)
-(15, 0.106794)
-(31, 0.119698)
-(63, 0.0900238)
-(127, 0.0938422)
-(255, 0.045615)
-(511, 0.0375595)
-(1023, 0.0395167)
-(2047, 0.0223799)
-(4095, 0.0199377)
-(8191, 0.00428302)
-(16383, 0.00567374)
-(32767, 0.00345214)
-(65535, 0.00413189)
-(131071, 0.00339832)
-(262143, 0.00155582)
-(524287, 0.00121594)
-(1048575, 0.000613453)
-*/
- }
-//]
-}
+// TODO remove file
\ No newline at end of file

Modified: sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.h
==============================================================================
--- sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.h (original)
+++ sandbox/acc_ecdf/libs/accumulators/ecdf/test/ks_sim.h 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,23 +1 @@
-///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright (C) 2005 Eric Niebler //
-// Copyright (C) 2011 Erwann Rogard //
-// Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-///////////////////////////////////////////////////////////////////////////////
-#ifndef LIBS_ACCUMULATORS_ECDF_KS_SIM_HPP_ER_2011
-#define LIBS_ACCUMULATORS_ECDF_KS_SIM_HPP_ER_2011
-#include <ostream>
-
-void test_ks_sim(
- std::ostream& os,
- double mean = 1.0,
- long n = 1,
- long factor = 2,
- long size = 20
-);
-
-#endif
-
-
+// TODO remove file

Modified: sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/Jamfile.v2
==============================================================================
--- sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/Jamfile.v2 (original)
+++ sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/Jamfile.v2 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,10 +1 @@
-rule ecdf-test ( name )
-{
- return [
- run $(name).cpp /boost/test//boost_unit_test_framework/<link>static ]
- ;
-}
-
-test-suite ecdf :
- [ ecdf-test ecdf ]
-;
+// TODO remove file
\ No newline at end of file

Modified: sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/ecdf.cpp
==============================================================================
--- sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/ecdf.cpp (original)
+++ sandbox/acc_ecdf/libs/accumulators/ecdf/test/unit_test/ecdf.cpp 2011-07-04 12:18:56 EDT (Mon, 04 Jul 2011)
@@ -1,21 +1,3 @@
-///////////////////////////////////////////////////////////////////////////////
-// acc_ecdf //
-// //
-// Copyright 2010 Erwann Rogard. Distributed under the Boost //
-// Software License, Version 1.0. (See accompanying file //
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) //
-///////////////////////////////////////////////////////////////////////////////
-#include <boost/test/test_tools.hpp>
-#define BOOST_ACCUMULATORS_ECDF_CHECK( p ) BOOST_CHECK( p )
-#include <libs/accumulators/ecdf/test/ecdf.cpp>
-#include <boost/test/unit_test.hpp>
-using boost::unit_test::test_suite;
-
-test_suite* init_unit_test_suite( int argc, char* argv[] )
-{
- test_suite* test = BOOST_TEST_SUITE( "ECDF" );
- test->add( BOOST_TEST_CASE( &test_ecdf ) );
- return test;
-}
+// TODO remove file
 
 


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk