Description Usage Arguments Value Examples
View source: R/expire_status_by_inventory.R
a version of cumsum that will stay within specified boundaries
1 | cumsum_bounded(v, low = 0, high = Inf)
|
v |
a numeric vector |
low |
numeric; lower bound |
high |
numeric; upper bound |
a numeric vector
1 2 3 | cumsum_bounded(c(0,-1,-100,1,7,-99,1,1,1,-1), low = -50)
cumsum_bounded(c(0,-1,-100,1,7,-99,1,1,1,-1)) ## low = 0 is default
cumsum_bounded(c(0,-1,-100,1,7,-99,1,1,1,-1), high = 5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.