tdpois: Convert data.frame into a data.frame of artificial Poisson...

Description Usage Arguments Value Examples

View source: R/tdpois.R

Description

Convert data.frame into a data.frame of artificial Poisson data with the interpolated Time varying covariate values

Usage

1
2
3
4
5
6
7
8
tdpois(
  dat,
  event = "z",
  et = "futime",
  t = "day",
  status = "status1",
  id = "id"
)

Arguments

dat

A data.frame

event

Name for Poisson response

et

Name of event time

t

Name of observation time

status

Numeric 1 for death 0 otherwise

id

Patient id

Value

A data.frame of artificial Poisson data

Examples

1
2
3
library(survival)
pbcseq$status1 <- as.numeric(pbcseq$status==2) ## deaths
pb <- tdpois(pbcseq) ## conversion

cardiomoon/ggGam documentation built on May 2, 2020, 9:58 a.m.