tag:blogger.com,1999:blog-8772916916708320394.post8180594090610362722..comments2016-09-23T08:39:59.334-07:00Comments on Quantitative Ecology: Model Validation: Interpreting Residual PlotsDaniel Hockinghttp://www.blogger.com/profile/07743548705954290964noreply@blogger.comBlogger8125tag:blogger.com,1999:blog-8772916916708320394.post-79275289284072593912013-08-15T07:56:55.216-07:002013-08-15T07:56:55.216-07:00Have you reached a conclusion about this?
I have t...Have you reached a conclusion about this?<br />I have the exact same problem.<br /><br />Thank you,<br />GonĂ§aloGonĂ§alohttps://www.blogger.com/profile/16149115938675889424noreply@blogger.comtag:blogger.com,1999:blog-8772916916708320394.post-63006175847480694392013-03-07T19:15:38.456-08:002013-03-07T19:15:38.456-08:00Hi, pleased to meet you. I'm Vivi may I get th...Hi, pleased to meet you. I'm Vivi may I get this journal or the paper? If you allow it, please send me an email to phiartea.emn@gmail.com<br /><br />thank you very much.mymathworldhttps://www.blogger.com/profile/00148530766356143104noreply@blogger.comtag:blogger.com,1999:blog-8772916916708320394.post-26410386418596062982012-09-21T02:41:25.885-07:002012-09-21T02:41:25.885-07:00Hi, this is exactly what I am thinking about too! ...Hi, this is exactly what I am thinking about too! Should we expect normaly distributed residuals in a diagnostic plot for a negative binomial model?? <br /><br />did you figure out someting on that?Unknownhttps://www.blogger.com/profile/06725038979832611092noreply@blogger.comtag:blogger.com,1999:blog-8772916916708320394.post-60471233718493153482012-01-24T07:44:00.944-08:002012-01-24T07:44:00.944-08:00Nathan - I was thinking about it some more. While ...Nathan - I was thinking about it some more. While the residuals follow a negative binomial distribution, is that what they should do? Isn't one of the assumptions of a GLMM that the error is ~N(0, sigma), meaning that the residuals should be normally distributed and centered on zero? The expectation of the response variable should be distributed following a NB (Y|X,b) ~ Nbin(location, scale) but the error should be normal if the distribution is specified correctly, no?Daniel Hockinghttps://www.blogger.com/profile/07743548705954290964noreply@blogger.comtag:blogger.com,1999:blog-8772916916708320394.post-21770736179837842342012-01-21T19:42:17.795-08:002012-01-21T19:42:17.795-08:00Correction: in the rnbinom function the term they ...Correction: in the rnbinom function the term they use is "size" rather than "scale" so the code should read:<br /><br />nbquant<-rnbinom(n=length(count), size=1.480, mu=mean(count))<br /><br />and then I get a nearly perfectly straight line. Thanks again Nathan.Daniel Hockinghttps://www.blogger.com/profile/07743548705954290964noreply@blogger.comtag:blogger.com,1999:blog-8772916916708320394.post-64615664940953223562012-01-03T18:48:14.413-08:002012-01-03T18:48:14.413-08:00Wow Nathan - that makes perfect sense! Thanks so m...Wow Nathan - that makes perfect sense! Thanks so much for sharing. It seem so obvious once you point it out. Thanks for showing how to create the negative binomial quantiles in R as well.Daniel Hockinghttps://www.blogger.com/profile/07743548705954290964noreply@blogger.comtag:blogger.com,1999:blog-8772916916708320394.post-51522649344588027232011-12-15T10:51:36.527-08:002011-12-15T10:51:36.527-08:00sorry, qqnorm should be qqplot
qqplot(nbquant,res...sorry, qqnorm should be qqplot<br /><br />qqplot(nbquant,resid(glmmPQLnb1))Nathanhttps://www.blogger.com/profile/16072284696369747012noreply@blogger.comtag:blogger.com,1999:blog-8772916916708320394.post-33089314402661005902011-12-15T10:42:16.394-08:002011-12-15T10:42:16.394-08:00Hi I have a suggestions on the issue of checking a...Hi I have a suggestions on the issue of checking assumptions for the glmmPQL model. I was also working with glmmPQL and getting a similar qqnorm plot of residuals, with a flat bottom and sharply increasing line (the left most plot in the second to last set of graphs from glmmPQLnb1). However, that is exactly the shape you'd expect from a negative binomial distribution (lots of zeros and then slowly tapering off as the value increases). You've plotted residuals that follow a negative binomial distribution against standard normal quantiles. Took me a while to figure this out too. <br /><br />I suggest you generate negative binomial quantiles:<br />nbquant<-rnbinom(n=length(count), scale=1.480, mu=mean(count))<br /><br />Then plot those quantiles against your residuals:<br />qqnorm(nbquant, resid(glmmPQLnb1)<br /><br />I think you'll find that your points fall along a straight line, suggesting that you did choose the right distribution. I had this issue too, took me a while to figure out, and once I did, I got a nice straight line.Nathanhttps://www.blogger.com/profile/16072284696369747012noreply@blogger.com