TABLE OF CONTENTS
CWrappers/cmkgr.spline.haz [ Functions ]
NAME
cmkgr.spline.haz --- wrapper for cInitGrHazSpline
FUNCTION
Wrapper for cInitGrHazSpline, which computes hazard loglikelihood gradient for initialization only.
SYNOPSIS
3374 cmkgr.spline.haz <- function(par, status, lp, frailrep, hazParY, hazParYcum, weight, 3375 B, C, P, penaltyType, sigma2, min)
INPUTS
see cmklik.spline.haz for inputs and outputs
SOURCE
3378 { 3379 gr <- as.double(rep(0, length(par))) 3380 out <- .C("cInitGrHazSpline", 3381 gr = gr, par = par, status = status, lp = lp, frailrep = frailrep, 3382 hazParY = hazParY, hazParYcum = hazParYcum, weight = weight, B = B, C = C, P = P, 3383 penaltyType = penaltyType, sigma2 = sigma2, ny = as.integer(length(lp)), 3384 nj = as.integer(length(par)), DUP = FALSE) 3385 gr <- out$gr 3386 gr <- gr - ifelse(par< min, 2 * (par - min), 0) 3387 return(gr) 3388 }