tests/new-ex/run.R

library(tidyverse)
ex1t <- ex1t %>%
  mutate(end.spell = as.integer(tstop==time))
  
mdl1 <- spdur(tstop ~ death + ethn, status.ov ~ death + ethn, data = ex1t,
               last = "end.spell", t.0 = "tstart", fail = "status.int",
              silent = TRUE)
summary(mdl1)

Try the spduration package in your browser

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

spduration documentation built on May 1, 2019, 6:32 p.m.