[R] GLMM(..., family=binomial(link="cloglog"))?

Spencer Graves spencer.graves at pdf.com
Mon Jun 7 20:48:27 CEST 2004


      Thanks, Andy, Doug, Deepayan.  I now have lme4 0.6-1 2004/05/31 
installed for R 1.9.1 alpha under Windows 2000.  When I tried the 
example below, GLMM ran, but the print method reported an error: 

Generalized Linear Mixed Model

Fixed: immun ~ 1
Data: guImmun
 log-likelihood:  -1440.052
Random effects:
 Groups Name        Variance Std.Dev.
 comm   (Intercept) 0.31686  0.5629 

Estimated scale (compare to 1)  0.9717356
Error in cm[, 1] : incorrect number of dimensions

      The following is a possibly simpler example that returns the same 
error message: 

 > simDF <- data.frame(yield=(1:4)/5, gp=factor(rep(1:2,2)), nobs=5)
 > simFit <- GLMM(yield~1, family=binomial, data=simDF, random=~1|gp, 
weights=nobs)
Iteration 1 Termination Criterion: 2.206532e-08
Iteration 2 Termination Criterion: 8.659736e-16
 > simFit
Generalized Linear Mixed Model

Fixed: yield ~ 1
Data: simDF
 log-likelihood:  -2.128803
Random effects:
 Groups Name        Variance   Std.Dev. 
 gp     (Intercept) 2.2065e-09 4.6974e-05

Estimated scale (compare to 1)  1
Error in cm[, 1] : incorrect number of dimensions
 >
      Any suggestions on what I should try next?  So far, I've only 
gotten this with an intercept-only model such as yield~1.  When I added 
a term from the help file example making it, "immun ~ kid2p", this error 
disappeared. 

      Thanks,
      Spencer Graves

Liaw, Andy wrote:

>As Doug said in his announcement, version 0.6-1 of lme4 (which is pure R
>code) depends on the Matrix package, version 0.8-7.  AFAICT the Windows
>binary on CRAN for Matrix is version 0.8-6.  Not sure if that will work with
>the current lme4...  It's probably best to wait for the right versions of
>these packages to propagate to appropriate places on CRAN...
>
>Best,
>Andy
>
>  
>
>>From: Spencer Graves
>>
>>Hi, Deepayan: 
>>
>>      Thanks for your reply.  How can I get the new release 
>>in a Windows 
>>2000 format, downloaded and properly installed? 
>>
>>      I tried "update.packages", but the new version has not yet 
>>migrated within reach of the default "update.packages" 
>>function call.  I 
>>tried downloading "lme4 0.6-0-2.tar.gz" from 
>>"http://www.stat.wisc.edu/%7Ebates/", unzipping it and 
>>replacing the old 
>>"\\R\rw1090pat\library\lme4" with the new.  Unfortunately, 
>>when I then 
>>tried to start R, I got a fatal error message: 
>>
>>      Error in loadNamespace(i[[1]], c(lib.loc, libPaths()), 
>>keep.source):  There is no package called 'Matrix'. 
>>
>>      Fortunately, I was able to restore R to apparently functioning 
>>order by merely restoring the old version. 
>>
>>      Is there something easy I can do to get "lme4 
>>0.6-0-2.tar.gz" to 
>>install properly for me?  Or do I need to wait until it 
>>migrates to my 
>>update.packages default ("http://cran.r-project.org") or some other 
>>designated CRAN mirror? 
>>
>>      Thanks for your excellent work in bringing this 
>>excellent software 
>>to its present state. 
>>
>>      Best Wishes,
>>      spencer graves
>>
>>Deepayan Sarkar wrote:
>>
>>    
>>
>>>On Tuesday 01 June 2004 17:25, Spencer Graves wrote:
>>> 
>>>
>>>      
>>>
>>>>     I'm having trouble using binomial(link="cloglog") with GLMM in
>>>>lme4, Version: 0.5-2, Date: 2004/03/11.  The example in the 
>>>>        
>>>>
>>Help file
>>    
>>
>>>>works fine, even simplified as follows:
>>>>
>>>>     fm0 <- GLMM(immun~1, data=guImmun, family=binomial,
>>>>random=~1|comm)
>>>>
>>>>     However, for another application, I need
>>>>binomial(link="cloglog"),
>>>>
>>>>and this generates an error for me:
>>>>        
>>>>
>>>>>fm0. <- GLMM(immun~1, data=guImmun,
>>>>>family=binomial(link="cloglog"),
>>>>>          
>>>>>
>>>>random=~1|comm)
>>>>Error in getClass(thisClass) : "family" is not a defined class
>>>>Error in GLMM(immun ~ 1, data = guImmun, family = binomial(link =
>>>>"cloglog"),  :
>>>>       S language method selection got an error when called from
>>>>internal dispatch for function "GLMM"
>>>>
>>>>     Any suggestions?
>>>>   
>>>>
>>>>        
>>>>
>>>This should work better in the new lme4 (0.6-x) announced 
>>>      
>>>
>>earlier today 
>>    
>>
>>>on r-packages. There is still a bug with cases (like in your 
>>>      
>>>
>>example) 
>>    
>>
>>>with only one fixed effect where the show and summary 
>>>      
>>>
>>methods produce 
>>    
>>
>>>an error, but that should be fixed soon.
>>>
>>>Deepayan
>>> 
>>>
>>>      
>>>
>>______________________________________________
>>R-help at stat.math.ethz.ch mailing list
>>https://www.stat.math.ethz.ch/mailman/listinfo/r-help
>>PLEASE do read the posting guide! 
>>http://www.R-project.org/posting-guide.html
>>
>>
>>    
>>
>
>______________________________________________
>R-help at stat.math.ethz.ch mailing list
>https://www.stat.math.ethz.ch/mailman/listinfo/r-help
>PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
>
>  
>




More information about the R-help mailing list