[R] Help Interpreting Linear Mixed Model
John Kane
jrkrideau at inbox.com
Mon Apr 27 13:42:36 CEST 2015
John Kane
Kingston ON Canada
> -----Original Message-----
> From: joshuamichaeldixon at gmail.com
> Sent: Mon, 27 Apr 2015 08:54:51 +0100
> To: thierry.onkelinx at inbo.be
> Subject: Re: [R] Help Interpreting Linear Mixed Model
>
> Hello Thierry,
>
> No, this isn't homework. Not that young unfortunately.
>
A few years ago a friend of mine and her daughter were neck-in-neck on who got their Ph.D first. What's this "not that young" business?
BTW, a better way to supply sample data is to use the dput() command.
Do a dput(mydata), copy the results into the email and you have supplied us with an exact copy of your data.
It is possible for many reasons that I will not read in your data, as you supplied it, in the format you have it in. This can lead to real confusion.
> Josh
>
>> On 27 Apr 2015, at 08:06, Thierry Onkelinx <thierry.onkelinx at inbo.be>
>> wrote:
>>
>> Dear Josh,
>>
>> Is this homework? Because the list has a no homework policy.
>>
>> Best regards,
>>
>> ir. Thierry Onkelinx
>> Instituut voor natuur- en bosonderzoek / Research Institute for Nature
>> and Forest
>> team Biometrie & Kwaliteitszorg / team Biometrics & Quality Assurance
>> Kliniekstraat 25
>> 1070 Anderlecht
>> Belgium
>>
>> To call in the statistician after the experiment is done may be no more
>> than asking him to perform a post-mortem examination: he may be able to
>> say what the experiment died of. ~ Sir Ronald Aylmer Fisher
>> The plural of anecdote is not data. ~ Roger Brinner
>> The combination of some data and an aching desire for an answer does not
>> ensure that a reasonable answer can be extracted from a given body of
>> data. ~ John Tukey
>>
>> 2015-04-27 2:26 GMT+02:00 Joshua Dixon <joshuamichaeldixon at gmail.com>:
>>> Hello!
>>>
>>> Very new to R (10 days), and I've run the linear mixed model, below.
>>> Attempting to interpret what it means... What do I need to look for?
>>> Residuals, correlations of fixed effects?!
>>>
>>> How would I look at very specific interactions, such as PREMIER_LEAGUE
>>> (Level) 18 (AgeGr) GK (Position) mean difference to CHAMPIONSHIP 18
>>> GK?
>>>
>>> For reference my data set looks like this:
>>>
>>> Id Level AgeGr Position Height Weight BMI YoYo
>>> 7451 CHAMPIONSHIP 14 M NA 63 NA 80
>>> 148 PREMIER_LEAGUE 16 D NA 64 NA 80
>>> 10393 CONFERENCE 10 D NA 36 NA 160
>>> 10200 CHAMPIONSHIP 10 F NA 46 NA 160
>>> 1961 LEAGUE_TWO 13 GK NA 67 NA 160
>>> 10428 CHAMPIONSHIP 10 GK NA 40 NA 160
>>> 10541 LEAGUE_ONE 10 F NA 25 NA 160
>>> 10012 CHAMPIONSHIP 10 GK NA 30 NA 160
>>> 9895 CHAMPIONSHIP 10 D NA 36 NA 160
>>>
>>>
>>> Many thanks in advance for time and help. Really appreciate it.
>>>
>>> Josh
>>>
>>>
>>>> summary(lmer(YoYo~AgeGr+Position+(1|Id)))
>>> Linear mixed model fit by REML ['lmerMod']
>>> Formula: YoYo ~ AgeGr + Position + (1 | Id)
>>>
>>> REML criterion at convergence: 125712.2
>>>
>>> Scaled residuals:
>>> Min 1Q Median 3Q Max
>>> -3.4407 -0.5288 -0.0874 0.4531 4.8242
>>>
>>> Random effects:
>>> Groups Name Variance Std.Dev.
>>> Id (Intercept) 15300 123.7
>>> Residual 16530 128.6
>>> Number of obs: 9609, groups: Id, 6071
>>>
>>> Fixed effects:
>>> Estimate Std. Error t value
>>> (Intercept) -521.6985 16.8392 -30.98
>>> AgeGr 62.6786 0.9783 64.07
>>> PositionD 139.4682 7.8568 17.75
>>> PositionM 141.2227 7.7072 18.32
>>> PositionF 135.1241 8.1911 16.50
>>>
>>> Correlation of Fixed Effects:
>>> (Intr) AgeGr PostnD PostnM
>>> AgeGr -0.910
>>> PositionD -0.359 -0.009
>>> PositionM -0.375 0.001 0.810
>>> PositionF -0.349 -0.003 0.756 0.782
>>>> model=lmer(YoYo~AgeGr+Position+(1|Id))
>>>> summary(glht(model,linfct=mcp(Position="Tukey")))
>>>
>>> Simultaneous Tests for General Linear Hypotheses
>>>
>>> Multiple Comparisons of Means: Tukey Contrasts
>>>
>>>
>>> Fit: lmer(formula = YoYo ~ AgeGr + Position + (1 | Id))
>>>
>>> Linear Hypotheses:
>>> Estimate Std. Error z value Pr(>|z|)
>>> D - GK == 0 139.468 7.857 17.751 <1e-04 ***
>>> M - GK == 0 141.223 7.707 18.323 <1e-04 ***
>>> F - GK == 0 135.124 8.191 16.496 <1e-04 ***
>>> M - D == 0 1.754 4.799 0.366 0.983
>>> F - D == 0 -4.344 5.616 -0.774 0.862
>>> F - M == 0 -6.099 5.267 -1.158 0.645
>>> ---
>>> Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
>>> (Adjusted p values reported -- single-step method)
>>>
>>> [[alternative HTML version deleted]]
>>>
>>> ______________________________________________
>>> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>> PLEASE do read the posting guide
>>> http://www.R-project.org/posting-guide.html
>>> and provide commented, minimal, self-contained, reproducible code.
>>
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
____________________________________________________________
FREE ONLINE PHOTOSHARING - Share your photos online with your friends and family!
Visit http://www.inbox.com/photosharing to find out more!
More information about the R-help
mailing list