I have data that I have fit using lme with the following structure (`Subject`

is implemented as a random effect in order to account for multiple paired comparisons):

`model <- lme(values ~ factor, data=mydata.df, random=~1|Subject, na.action=na.omit, contrasts=c("contr.sum","contr. poly")) `

`anova(model)`

performs an F test and reports the significance of the relationship between `values`

and `factor`

. Then I use `glht`

to do posthoc comparisons among the levels of `factor`

. I don't want `summary`

to apply a correction for multiple comparisons, I just want the raw p-values, because later I pool all the raw p-values for a larger set of related models and hypotheses, and perform a false discovery rate (FDR) correction.

I'm having trouble navigating the documentation to determine exactly what statistical test is being performed by `glht`

. Is it performing univariate t-tests between two factor levels at a time, without considering pooled variance across all levels, or is it in fact considering the full variance of the model (that's what I want it to do)? Actually, it reports z values, not t values, so does that imply that it is referring to the population variance? Is the test, then, simply called a "z-test"?

**Contents**hide

#### Best Answer

It does individual $z$ tests (asymptotic $t$ tests, since df are not available) for each comparison. It uses the results of `vcov`

to obtain standard errors for each comparison. These use the model error, not individual parts of the dataset.

You can specify `type="fdr"`

directly though, as `glht`

can support all the methods in `p.adjust.methods`

.

### Similar Posts:

- Solved – What statistical test is performed by summary(glht(model, linfct=mcp(factor=”Tukey”)), test=adjusted(type=”none”))
- Solved – What statistical test is performed by summary(glht(model, linfct=mcp(factor=”Tukey”)), test=adjusted(type=”none”))
- Solved – Correcting for multiple pairwise comparisons with GAM objects {mgcv} in R
- Solved – How to setup and interpret ANOVA contrasts with the car package in R
- Solved – How to setup and interpret ANOVA contrasts with the car package in R