R/makeinstantaneous.R

Defines functions make.instantaneous

Documented in make.instantaneous

make.instantaneous <- function(cumulate.data){
  firstdiff <- function(x) {
    shifted <- c(0,x[1:(length(x)-1)])
    x-shifted
  }
  return(firstdiff(cumulate.data))
}

Try the DIMORA package in your browser

Any scripts or data that you put into this service are public.

DIMORA documentation built on Oct. 7, 2023, 5:07 p.m.