diff --git a/basis/math/statistics/statistics-docs.factor b/basis/math/statistics/statistics-docs.factor index 31233fd68c..b40c3bb030 100644 --- a/basis/math/statistics/statistics-docs.factor +++ b/basis/math/statistics/statistics-docs.factor @@ -255,7 +255,6 @@ ARTICLE: "cumulative" "Computing cumulative sequences" "Cumulative mapping combinators:" { $subsections cum-map - cum-map0 } "Cumulative math:" { $subsections diff --git a/basis/math/statistics/statistics.factor b/basis/math/statistics/statistics.factor index 4dffd52afb..e68817ec37 100644 --- a/basis/math/statistics/statistics.factor +++ b/basis/math/statistics/statistics.factor @@ -336,14 +336,11 @@ ALIAS: std sample-std : cum-map ( seq identity quot -- seq' ) swapd [ dup ] compose map nip ; inline -: cum-map0 ( seq identity quot -- seq' ) - accumulate nip ; inline - : cum-sum ( seq -- seq' ) 0 [ + ] cum-map ; : cum-sum0 ( seq -- seq' ) - 0 [ + ] cum-map0 ; + 0 [ + ] accumulate nip ; : cum-product ( seq -- seq' ) 1 [ * ] cum-map ;