R/lt.R

Defines functions lt

Documented in lt

#' Specification of covariates entering the long-term part
#' in a promotion time cure model.
#' @keywords internal
#' @export

# Covariates entering the long-term survival (proba to be cured)
lt <- function(...) {
  lt.covariates <- as.list(substitute(list(...)))[-1]
  if (length(lt.covariates) == 1) {
    gsub(" + ", "+", lt.covariates, fixed = TRUE)
  } else{
    paste(unlist(lt.covariates),  collapse = "+")
  }
}

Try the blapsr package in your browser

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

blapsr documentation built on Aug. 20, 2022, 5:05 p.m.