itime <- c(1, 2, 3, 4, 5, 6, 7, 8)
delta <- c(0, 1, 0, 1, 1, 1, 0, 1)
isotNEW2(x=itime, y=delta, a=0.5, b=0.5)
## $x
## [1] 0.5 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 8.5
##
## $y
## [1] 0.00 0.00 0.50 0.50 0.75 0.75 0.75 0.75 1.00 1.00
#### the correct answer is F(t) = 0, .5, .5, .75, .75, .75, .75, 1
#### at the ordered itime, augumented by a and b.
isotNEW2(x=itime, y=delta, a=0.5, b=0.5, LONG=FALSE)
## $x
## [1] 2 4 8
##
## $y
## [1] 0.50 0.75 1.00 #### for time t < 2, F(t) = 0 by right cont.
Run the code above in your browser using DataLab