]> gitweb.factorcode.org Git - factor.git/commitdiff
math.statistics: just use accumulate for now.
authorJohn Benediktsson <mrjbq7@gmail.com>
Tue, 4 Dec 2012 16:56:21 +0000 (08:56 -0800)
committerJohn Benediktsson <mrjbq7@gmail.com>
Tue, 4 Dec 2012 16:56:21 +0000 (08:56 -0800)
basis/math/statistics/statistics-docs.factor
basis/math/statistics/statistics.factor

index 31233fd68c85caae04dbea2722c57893e3c3a0ed..b40c3bb0304f5e26fe82c5b0555b2b4b7f61ee1d 100644 (file)
@@ -255,7 +255,6 @@ ARTICLE: "cumulative" "Computing cumulative sequences"
 "Cumulative mapping combinators:"
 { $subsections
     cum-map
-    cum-map0
 }
 "Cumulative math:"
 { $subsections
index 4dffd52afb84af5e3b0fb117bd56a5604cfccd71..e68817ec375865212d043dad26e8b0125eedb4d5 100644 (file)
@@ -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 ;