Hi all, I'm using PROC NLMIXED to generate a multivariate nonlinear mixed-effects model. I have two continuous longitudinal response (A1,A2). I attached the data sample here: I try to use logistic nonlinear mixed effect model to fit each response across TU. and assume all the random variables follow a joint multivariate normal distribution. The SAS code as follows: proc nlmixed data = data1 method = gauss gconv = 0;
parms b1l=190 b2l=700 b3l=350 s2u1l=1000 s2el=60 s2u2l=1000
b1k=190 b2k=700 b3k=350 s2u1k=1000 s2u2k=1000 s2ek=60 cov_u1lk cov_u2lk;
pi = arcos(-1);
num1 = b1l+u1l;
ex1 = exp(-(TU -(b2l + u2l))/b3l);
den1 = 1 + ex1;
num2 = b1k+u1k;
ex2 = exp(-(TU -(b2k + u2k))/b3k);
den2 = 1 + ex2;
if variable = "A1" then predv = num1/den1;
else if variable = "A2" then predv = num2/den2;
/*here I need to write down the log likelihood function (ll)*/
model value ~ general(ll);
random u1l u2l u1k u2k ~ normal([0,0,0,0],[s2u1l,0,s2u2l,cov_u1lk,0,s2u1k,0,cov_u2lk,0,s2u2k]) subject=ID;
run; But I do not know how to write the log likelihood function. So, if anyone has any suggestions or could point me towards useful resources that would be great. Thanks a lot.
... View more