[R-sig-ME] questions on MCMCglmm
YA
x|nx|813 @end|ng |rom 126@com
Mon May 25 11:43:42 CEST 2020
Dear list,
I am using MCMCglmm package in R for my multilevel multinomial logistic regression model. I have a three category level1 unordered multinomial outcome 'nomial', which was coded as 0,1,2, a level1 continuous predictor 'IT1', and a level2 continuous predictor 'age', the ID variable is 'ID'. My questions are:
1. The regression coeffecient of IT1 is 0.120220, but which category of 'nomial' does the coefficient concern? how to interpret it?
2. Although I have got the model run properly, I dont quite understand what the 'rcov = ~us(trait):units' do in the model, only that the model cant run without this part. I have read the coursenote on the website several times, but still have not figured it out.
3. What does 'us','idh', 'ihv' stands for (the author uses them to refer to covariance structure, are they initials of some terminologies)?
4. I tried to make predictions with IT1=3 and age=23, I got error suggesting "object 'nomial' not found", but 'nomial' is exactly what I am trying to predict. How to understand the logic behind this?
So the model fit and prediction are as below:
> m10=MCMCglmm(as.factor(nomial)~IT1+age,random=~ID,data=dat,rcov = ~us(trait):units,family='categorical')
> summary(m10)
Iterations = 3001:12991
Thinning interval = 10
Sample size = 1000
DIC: 358.2906
G-structure: ~ID
post.mean l-95% CI u-95% CI eff.samp
ID 28.75 18.64 38.81 767.4
R-structure: ~us(trait):units
post.mean l-95% CI u-95% CI eff.samp
traitnomial.1:traitnomial.1.units 0.04237 0.01597 0.13210 10.77
traitnomial.2:traitnomial.1.units -0.21941 -0.39132 -0.07699 6.04
traitnomial.1:traitnomial.2.units -0.21941 -0.39132 -0.07699 6.04
traitnomial.2:traitnomial.2.units 1.69265 1.21517 2.21141 23.81
Location effects: as.factor(nomial) ~ IT1 + age
post.mean l-95% CI u-95% CI eff.samp pMCMC
(Intercept) 34.541008 -15.319976 78.613352 931.637 0.120
IT1 0.120220 0.009121 0.343275 6.204 0.004 **
age -1.404272 -3.267662 0.659993 931.605 0.130
---
Signif. codes: 0 ��***�� 0.001 ��**�� 0.01 ��*�� 0.05 ��.�� 0.1 �� �� 1
> predict.MCMCglmm(m10,data.frame(IT1=3,age=23),type='response')
Error in eval(inp, data, env) : object 'nomial' not found
Thank you very much.
Best regards,
YA
[[alternative HTML version deleted]]
More information about the R-sig-mixed-models
mailing list