survIC: Generate survival model objects

Description Usage Arguments Details Value Author(s) Examples

Description

Function to generate a latent variable model for interval censored survival times.

Usage

1
2
survIC(scale.time = 1/100, shape.time = 1, n.inspections = 5,
  schedule = 10, punctuality = 5)

Arguments

scale.time

Weilbull scale for latent time

shape.time

Weilbull shape for latent time

n.inspections

Number of inspection times

schedule

Mean of the waiting time between adjacent inspections.

punctuality

Standard deviation of waiting time between inspections.

Details

Based on the functionality of the lava PACKAGE the function generates a latent variable model with a latent time and a censoring mechanism (censtime, inspection1,inspection2,...,inspectionK).

The function sim.survIC then simulates interval censored times.

Value

A latent variable model object lvm

Author(s)

Thomas Alexander Gerds

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
## Not run: 
library(lava)
library(prodlim)
# generate survival model based on exponentially
# distributed times
m <- survIC(scale.time=1/50, shape.time=0.7)
round(sim(m,6),1)

# Estimate the parameters of the Weibull models
# based on the uncensored exact event times
# and the uncensored illstatus.
set.seed(18)
d <- sim(m,100,latent=FALSE)
d$uncensored.status <- 1
f <- shr(Hist(time=list(L,R),event=uncensored.status)~1,
         data=d,
         conf.int=FALSE)
print(f)

## End(Not run)

SmoothHazard documentation built on May 1, 2019, 8 p.m.