[R-sig-ME] Unclear output from MCMCglmm with categorical predictors
Walid Mawass
w@lidm@w@@@10 @ending from gm@il@com
Wed Nov 7 18:36:17 CET 2018
Hello,
by adding -1 into your model's formula, you are explicitly calling for no
intercept term to be included in the estimates. If you do want an intercept
term which would include a baseline level for each of your categorical
variables then the syntax should be:
MCMCglmm(Activity ~1 + Habitat + Diet + log(Mass) + Max.Temp... (explicit
call for intercept term)
or
MCMCglmm(Activity ~ Habitat + Diet + log(Mass) + Max.Temp... (implicit call
for intercept term)
Hope this helps
--
Walid Mawass
Ph.D. candidate in Cellular and Molecular Biology
Population Genetics Laboratory
University of Québec at Trois-Rivières
3351, boul. des Forges, C.P. 500
Trois-Rivières (Québec) G9A 5H7
Telephone: 819-376-5011 poste 3384
On Wed, Nov 7, 2018 at 12:09 PM <roimaor using post.tau.ac.il> wrote:
> Dear list members,
>
> I have a model with categorical response and categorical + continuous
> predictors.
>
> My model has two categorical predictors: "diet" (3 levels) and
> "habitat" (6 levels):
>
> THRE1 <- MCMCglmm(Activity ~ -1 + Habitat + Diet + log(Mass) + Max.Temp,
> prior = list(R = list(V = 1, fix = 1)),
> ginverse = list(Binomial=INphylo$Ainv),
> family = "threshold",
> data = Tdata)
>
> If I understand correctly, in this configuration the algorithm
> shouldn't return estimated values for the effect of each level of a
> categorical predictor, instead, it returns a contrast between that
> level and another level which was arbitrarily chosen as the base
> level. Each species (data point) has a value for each of these traits,
> so I would expect them to be estimated independently, meaning that one
> level of each predictor should be the 'baseline' and absorbed into the
> global intercept. In that case I expect 2 contrasts to be returned for
> diet categories and 5 contrasts for habitat.
>
> However, I get 2 estimates (presumably contrasts) for diet categories,
> and 6 for habitat categories, i.e., no habitat category was designated
> as baseline, which makes me question whether the estimates are
> contrasts or actual effect sizes.
>
> My questions:
> - Is the algorithm pooling all the predictor categories as if they
> were a single trait with 8 levels?
> - If the habitat effect estimates are contrasts - what are they compared
> to?
> - If they are effect sizes - what did I do to not get the contrasts as
> I expected?
>
> Any help would be much appreciated!
> Thanks,
> --
> Roi Maor
> PhD candidate
> School of Zoology, Tel Aviv University
> Centre for Biodiversity and Environment Research, UCL
>
> _______________________________________________
> R-sig-mixed-models using r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>
[[alternative HTML version deleted]]
More information about the R-sig-mixed-models
mailing list