search for: hesscomp

Displaying 1 result from an estimated 1 matches for "hesscomp".

Did you mean: headcomp
2013 Mar 10
0
Steepest Ascent Algorithm
...nction #w = 0 or 1 depending on whether they were censored or not #t is the suvival time #d is 0 if they were the control group and 1 if they were in the treatment group #theta is a vector of paramters (a,Bo, and B1 over which to maximize upon lordata[4,3] like<-function(theta,data,gcomp=FALSE,hesscomp=FALSE) { a = theta[1] Bo=theta[2] B1=theta[3] d=data[,1] #treatment w=data[,2] #censored t=data[,3] #survival time mu = (t^a)*exp(Bo+d*B1) l = sum(w*log(mu)-mu+w*log(a/t)) if(gcomp==TRUE) { grad=matrix(0,3,1) grad[1]=sum(w*log(t)-mu*log(t)+w/a) #alpha...