[R-sig-ME] glmm with a tweedie distribution

Danson, Bryan Bryan.Danson at MyFWC.com
Thu Mar 22 16:40:25 CET 2012


Hi Wayne,

Thank you for the help.  The summary function does work once the "nlme" package is removed.  I was able to get the bcpglmm() function to work as well.  However, the results give a "Mean", "SD", "Naïve SE", and "Time-series SE" for each trap type.  And I am confused to how to interpret this.

I supposed I should have prefaced all of these emails with the fact that I have very little statistical background.  I have taken courses in undergrad and graduate school, however they are introductory courses and fall far short of this level of mixed-modeling.  I am therefore trying to teach myself this modeling.  I have ordered a few books that have been mentioned on this list to help, I am just waiting on them to come in.  

But with that in mind, thank you all so much for your help. I have learned a great deal so far.  

Bryan

-----Original Message-----
From: Zhang,Yanwei [mailto:Yanwei.Zhang at cna.com] 
Sent: Wednesday, March 21, 2012 10:58 PM
To: Danson, Bryan; r-sig-mixed-models at r-project.org
Subject: RE: Re: [R-sig-ME] glmm with a tweedie distribution

Hi Bryan, 

The "cpglmm" uses the "glm.fit" function to generate initial values. So the "glm.fit does not converge" message means that when generating the initial values using GLM, the model does not converge. But this should not be a problem as long as you get a converged "cpglmm" estimate - the final estimates are independent of the initial values. I suspect if you supply initial values, this message will go away. But thank you for reporting this - I will suppress this kind of message in the new release to make it less confusing. 

I believe the "summary" function does not work because you have the "nlme" package in front of the "cplm" package in the search path. If you just detach the "nlme" package, it should work. 

You might want to use the Bayesian tweedie mixed models to assess the "p-values". The function "bcpglmm" does that, but the released version is not quite stable. I was using a block Metropolis update for the random effects, but this oftentimes leads to poor convergence because of the difficulty in tuning the proposal covariance matrix. In the development version, I have added an option to perform the naïve Gibbs sampler, which proves to be much easier to tune, although at the cost of slower speed. The new version should be released within a month. 

Thanks.

Regards, 
Wayne   
 

-----Original Message-----
From: r-sig-mixed-models-bounces at r-project.org [mailto:r-sig-mixed-models-bounces at r-project.org] On Behalf Of Danson, Bryan
Sent: Wednesday, March 21, 2012 11:09 AM
To: r-sig-mixed-models at r-project.org
Subject: Re: [R-sig-ME] glmm with a tweedie distribution

>  This is probably harmless -- it means that an intermediate GLM step 
> didn't quite work,

>  probably because you have strongly separated data (i.e. some places/factor combinations etc.

>  with all-zero or all-one data)

I do have strongly separated data, as some trap types did not move at all (therefore all zeros), and others moved a lot.


>  Can we see the results of sessionInfo()? I suspect you have a problem 
> with methods from some

>  packages masking others.  If you have installed lme4 from r-forge, I 
> suspect you should re-

>  install it from CRAN ...

The results from sessionInfo(model) are:

Error in as.list.default(X) :
  no method for coercing this S4 class to a vector

The packages in my workspace were (installed in order):

car
ggplot2
sos
glmmADMB
lme4
nlme
plotrix
cplm

I tried removing all that had to do with GLMMs (glmmADMB, lme4, nlme, cplm) and reinstalling only 'cplm' and have been able to get the summary() function to work.  This results in a list of t-values for each trap type.  From my background reading, I understand that p-values are difficult to determine in GLMMs, however, I am not sure how to interpret the t-values to estimate which trap type is different from the wood traps.  Here are the resulting t-values:

                                                    Estimate Std. Error   t value
(Intercept)                               0.05134    0.68273     0.075
trap_type5-slat                     -1.59469    0.44568    -3.578
trap_typevw-6                      -3.79851    0.71923    -5.281
trap_typevw-sponge         -2.41591    0.52667    -4.587
trap_typewire basket      -27.93281  386.0848    -0.072
trap_typewire on frame   -4.77199    0.90967    -5.246
trap_typewood-6                  0.29933    0.32652     0.917
trap_typewood-thick          0.27437    0.34785     0.789
trap_typeyb-6                      -4.27295    0.80548     -5.305
trap_typeyf-6                       -2.88076    0.58270     -4.944

According to the exploratory plot, it is likely that the wood-6 and wood-thick traps are not different from the standard control.  The others are probably different.

Is there a way to know for sure?

Thank you again,

Bryan


_____________________
Bryan Danson
Biological Scientist I
Fish and Wildlife Research Institute
Florida Fish and Wildlife Conservation Commission

"The significant problems we have cannot be solved at the same level of thinking with which we created them."
~Albert Einstein




	[[alternative HTML version deleted]]

_______________________________________________
R-sig-mixed-models at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models

NOTICE:  This e-mail message, including any attachments and appended messages, is for the sole use of the intended recipients and may contain confidential and legally privileged information.
If you are not the intended recipient, any review, dissemination, distribution, copying, storage or other use of all or any portion of this message is strictly prohibited.
If you received this message in error, please immediately notify the sender by reply e-mail and delete this message in its entirety.




More information about the R-sig-mixed-models mailing list