|
|||
|
--- "Brice X. Semmens" <semmens@u.washington.edu> wrote:
> Wow Dale, I hope the Hutch pays you the big bucks, because you > deserve them. > If not let me know and Ill send you a check !> > Thanks so much for the reams of insight and correctified code. I will > take > into account your qualms about fitting a random effects model with > the data. > FYI, I wasn't able to get your nlmixed model to converge unless I > gave it > some initial parameterization. > Hmm, that is odd. I just ran the following code and had no problems whatsoever (although I would note that NLMIXED required 54 iterations). Try executing exactly the following and see if you have problems. data reef; input trt$ site bite; if (trt='1') then do; x1 = 1; x2 = 0; end; else do; x1 = 0; x2 = 1; end; datalines; 1 1 232 1 1 247 1 1 276 1 1 448 1 1 207 1 1 228 1 2 193 1 2 117 1 2 307 1 2 318 1 2 238 1 2 263 1 2 219 1 2 260 1 2 208 1 2 242 1 2 358 1 2 372 2 3 75 2 3 97 2 3 194 2 3 247 2 3 59 2 3 83 2 3 76 2 3 97 2 3 97 2 3 187 2 3 202 2 3 87 2 3 237 2 4 212 2 4 242 2 4 260 2 4 336 2 4 257 2 4 78 2 4 295 run; proc mixed data = reef COVTEST /*method=ml*/; CLASS trt site; MODEL bite = trt / s; RANDOM site(trt); RUN; proc nlmixed data=reef fconv=1E-16; eta = b0 + alpha + b1*x1; model bite ~ normal(eta, V_resid); random alpha ~ normal(0, V_site) subject=site; run; You might also try fitting the NLMIXED model with a little bit different parameterization of the random effects as shown in the following two versions: proc nlmixed data=reef fconv=1E-16; eta = b0 + alpha + b1*x1; model bite ~ normal(eta, std_resid**2); random alpha ~ normal(0, std_site**2) subject=site; estimate "V_resid" std_resid**2; estimate "V_site" std_site**2; run; proc nlmixed data=reef fconv=1E-16; eta = b0 + alpha + b1*x1; model bite ~ normal(eta, exp(2*log_Vresid)); random alpha ~ normal(0, exp(2*log_Vsite)) subject=site; estimate "V_resid" exp(2*log_Vresid); estimate "V_site" exp(2*log_Vsite); run; These each require fewer iterations to achieve convergence than when the NLMIXED model is parameterized in terms of the variance components directly. However, the likelihood value is not quite as good for these two models as it was for the model parameterized in terms of the variance components. Parameter estimates do also differ from the PROC MIXED results a little bit more for these models than for the model parameterized in the variance components directly. I like to employ the last parameterization shown above, since it provides a monotonic transformation of the variance components, but constrains the variance component estimates to be positive. I would note that providing good initial parameter estimates can be important in obtaining convergence. I just wonder why you did not achieve convergence given the code I presented yesterday. Best wishes, Dale ===== --------------------------------------- Dale McLerran Fred Hutchinson Cancer Research Center mailto: dmclerra@NO_SPAMfhcrc.org Ph: (206) 667-2926 Fax: (206) 667-5977 --------------------------------------- __________________________________ Do you Yahoo!? Yahoo! Mail - Easier than ever with enhanced search. Learn more. yahoo.com/mail_250" target="_blank">http://info.mail.yahoo.com/mail_250 |
|
|
||||
|
||||
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Re: Difference between PROC SORT NODUPKEY and PROC SQL? | Ian Whitlock | Newsgroup comp.soft-sys.sas | 0 | 03-02-2009 08:49 PM |
| Again: PROC NLMIXED and more that two levels | Sebastian Hein | Newsgroup comp.soft-sys.sas | 3 | 10-24-2006 04:28 PM |
| Re: HOW DO I SEPARATE SEVERAL PROC IMPORTS? | Choate, Paul@DDS | Newsgroup comp.soft-sys.sas | 0 | 05-18-2006 05:11 PM |
| FW: HOW DO I SEPARATE SEVERAL PROC IMPORTS? | Choate, Paul@DDS | Newsgroup comp.soft-sys.sas | 0 | 05-18-2006 04:24 PM |
| Re: about contrast in PROC NLMIXED | Dale McLerran | Newsgroup comp.soft-sys.sas | 0 | 11-11-2005 08:50 PM |