[R] Questions about the glht function for planned comparison

2013-01-10 Thread Wendy Qiao
Hi all,

I've posted this question before, but did not get any reply. I post it
again here and see if anybody can help. Thank you.

I have a nested model with the following effects
fixed: treatments
random: experiment_date

I used lme() to model the data
mod1 - lme(N_cells ~treatments-1, random=~1|experiment_date, method='ML')

Then I want to compare all the other treatments to the control (included in the
treatments in mod1). After a fair amount of searching around, I decided
to use glht() from the multcomp package (any other suggestions?).
lvl.treatments=table(treatments)
K = contrMat(lvl.treatments,type='Dunnett',base=1)
mc-glht(mod1, linfct=mcp(treatments=K),alternative='greater')

But I got the following error:
Error in contr.treatment(n = 0L) :
  not enough degrees of freedom to define contrasts

I tried to extract the df parameter using modelparm(), but the
function couldn't
be applied to lme:
Error in UseMethod(modelparm) :
  no applicable method for 'modelparm' applied to an object of class lme

The degree of freedom of the fixed effect was 194. I tried to specify
the number
in glht, but got the same error as not enough degrees of freedom to define
contrasts.

Does anyone know what's happening and how I could possibly solve the problem?
Thank you so much.

Best,
Wendy

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
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.


[R] change email subscription

2010-02-22 Thread Wendy Qiao
Dear R team,

 

As this is a university email address with very small inbox limit, can I
please change my R email subscription to another email address instead of
this  one? My new email address is wendy2.q...@gmail.com. I have change my
email in my profile, but seems that does not change my subscription.

 

Thank you. 

Wendy 


[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
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.