R/cumsumprop.R
cumsumprop.Rd
Proportion of cumulative sum over sum
cumsumprop(x)
Numeric vector
the proportion cumulative sum over sum
x <- 1:4 cumsumprop(x) ## 0.1, 0.3, 0.6, 1 #> [1] 0.1 0.3 0.6 1.0