dat {coxsei}R Documentation

A simulated data set from a CoxSEI model

Description

Simulated from a CoxSEI model with an exponential excitation function and an AR order 2 for the self-excitation effects. Generated using the following code: set.seed(1); n.smp <- 50; z <- matrix(NA,n.smp,3); for(i in 1:n.smp) z[i,] <- round(c(runif(1,0.5,1.5),runif(1,1.5,2.5),rbinom(1,1,0.5)),2); dat <- coxseisim(1:3*0.2,c(0.07,10),censor=rlnorm(1,0,0.1),m=2, Z=function(x)matrix(z[1,],length(x),3,byrow=T)); dat$id <- 1; for(i in 2:n.smp){ dattmp <- coxseisim(1:3*0.2,c(0.07,10),censor=rlnorm(1,0,0.1),m=2, Z=function(x)matrix(z[i,],length(x),3,byrow=T)) dattmp$id <- i; dat <- rbind(dat,dattmp) }

Usage

data(dat)

Format

A data frame with 307 observations on the following 6 variables.

Y

a numeric vector

delta

a numeric vector

Z.1

a numeric vector

Z.2

a numeric vector

Z.3

a numeric vector

id

a numeric vector

Examples

data(dat)
## maybe str(dat) ; plot(dat) ...

[Package coxsei version 0.3 Index]