[R-sig-ME] lme for data that is not normally distributed
Highland Statistics Ltd
highstat at highstat.com
Wed Aug 3 15:41:19 CEST 2016
Moses....your question assumes that we are telepathic and can see your
results. In order to get advise from other people it would be useful if
you can visualise your results. Or provide a reproducible example. Based
on a p-value from a normality test no one can tell you what to do.
Distance is strictly positive? Try a gamma?
Alain
Does type = "response" work for an lme?
On 03/08/2016 22:45, moses selebatso wrote:
> Thank very much for your helpful advice. I ran the model and tested
> the residuals. They are not normally distributed, and I am still stuck
> with how I proceed. See below
>
> m1<- lme(Distance~Time,random=~1|ID,data=data)
> res1=residuals(m1,type="response")
>
> shapiro.test(res1)
> Shapiro-Wilk normality test
>
> data: res1
> W = 0.89575, p-value = 1.594e-13
> //
> /Regards,/
> /
> /
> *Moses **SELEBATSO*
> /Home: (+267) 318 5219 (H) /
> /Mobile: (+267) 716 39370 or (+267) 738 39370/
> /"Those who will ALWAYS agree with you may be oppressed by you"/
>
>
> On Wednesday, 3 August 2016, 12:15, Highland Statistics Ltd wrote:
>
>
>
>
>
> > Date: Wed, 3 Aug 2016 09:40:20 +0000 (UTC)
> > From: moses selebatso <selebatsom at yahoo.co.uk <javascript:return>>
> > To: R-sig-mixed-models <r-sig-mixed-models at r-project.org
> <javascript:return>>
> > Subject: [R-sig-ME] lme for data that is not normally distributed
> > Message-ID:
> > <127496753.15122202.1470217220406.JavaMail.yahoo at mail.yahoo.com
> <javascript:return>>
> > Content-Type: text/plain; charset="UTF-8"
> >
> > ?Hello
> > I have some data that I would to analyse with mixed models
> (lme). As a standard procedure I tested for the normality of the
> data and it is not normal. Any ideas of how deals with this kind
> of data? I have a sample below and the model that I was hoping to
> use (if?the data?was normal)
> > m <- lme(Distance~Time,random=~1|ID,data=data).
>
>
> Checking normality of the response variable before doing the
> analysis is
> a misconception. Why should it be normally distributed? Fit your
> model
> and check your residuals for normality.
>
>
> Alain
>
> >
> >
> >
> >
> > |
> >
> >
> > | ID |
> >
> >
> > | Time |
> >
> >
> > | Distance |
> >
> >
> > |
> >
> >
> > | 10187A |
> >
> >
> > | Pre_dry |
> >
> >
> > | 4.31287 |
> >
> >
> > |
> >
> >
> > | 10187A |
> >
> >
> > | Pre_dry |
> >
> >
> > | 6.867578 |
> >
> >
> > |
> >
> >
> > | 10187A |
> >
> >
> > | Pre_dry |
> >
> >
> > | 4.640427 |
> >
> >
> > |
> >
> >
> > | 10187A |
> >
> >
> > | Post_dry |
> >
> >
> > | 4.497807 |
> >
> >
> > |
> >
> >
> > | 10187A |
> >
> >
> > | Post_dry |
> >
> >
> > | 9.726069 |
> >
> >
> > |
> >
> >
> > | 10187A |
> >
> >
> > | Post_dry |
> >
> >
> > | 5.150089 |
> >
> >
> >
> >
> > Regards,
> > Moses SELEBATSO?
> > [[alternative HTML version deleted]]
> >
> >
> >
> > ------------------------------
> >
> > Subject: Digest Footer
> >
> > _______________________________________________
> > R-sig-mixed-models mailing list
> > R-sig-mixed-models at r-project.org <javascript:return>
> > https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
> >
> > ------------------------------
> >
> > End of R-sig-mixed-models Digest, Vol 116, Issue 4
> > **************************************************
> >
>
> --
> Dr. Alain F. Zuur
>
> First author of:
> 1. Beginner's Guide to GAMM with R (2014).
> 2. Beginner's Guide to GLM and GLMM with R (2013).
> 3. Beginner's Guide to GAM with R (2012).
> 4. Zero Inflated Models and GLMM with R (2012).
> 5. A Beginner's Guide to R (2009).
> 6. Mixed effects models and extensions in ecology with R (2009).
> 7. Analysing Ecological Data (2007).
>
> Highland Statistics Ltd.
> 9 St Clair Wynd
> UK - AB41 6DZ Newburgh
> Tel: 0044 1358 788177
> Email: highstat at highstat.com <javascript:return>
> URL: www.highstat.com
>
> _______________________________________________
> R-sig-mixed-models at r-project.org <javascript:return> mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>
>
--
Dr. Alain F. Zuur
First author of:
1. Beginner's Guide to GAMM with R (2014).
2. Beginner's Guide to GLM and GLMM with R (2013).
3. Beginner's Guide to GAM with R (2012).
4. Zero Inflated Models and GLMM with R (2012).
5. A Beginner's Guide to R (2009).
6. Mixed effects models and extensions in ecology with R (2009).
7. Analysing Ecological Data (2007).
Highland Statistics Ltd.
9 St Clair Wynd
UK - AB41 6DZ Newburgh
Tel: 0044 1358 788177
Email: highstat at highstat.com
URL: www.highstat.com
[[alternative HTML version deleted]]
More information about the R-sig-mixed-models
mailing list