Displaying 20 results from an estimated 9000 matches similar to: "question about mixed effects model"
2005 Feb 08
0
2: lme4 ---> GLMM
Douglas Bates wrote:
>
> The GLMM function in the lme4 package allows you to specify crossed
> random effects within the random argument without the need for the
> pdBlocked and pdIdent constructions. Simply ensure that your grouping
> factors are defined in such a way that each distinct group has a
> different level in the grouping factor (this is usually not a problem
2012 Jun 21
1
lme random effects in additive models with interaction
Hello,
I work with a mixed model with 4 predictor variables Time, Size, Charge,
Density and Size, Charge, Density are factors, all with two levels. Hence I
want to put their interactions with Time into the model. But, I have two
data sets (Replication 1 and 2) and I want that Replication is random
effect. Here is my code:
knots <- default.knots(Time)
z <- outer(Time, knots, "-")
2007 May 25
0
Help with complex lme model fit
Hi R helpers,
I'm trying to fit a rather complex model to some simulated data using
lme and am not getting the correct results. It seems there might be
some
identifiability issues that could possibly be dealt with by
specifying
starting parameters - but I can't see how to do this. I'm comparing
results from R to those got when using GenStat...
The raw data are available on the
2006 Jul 28
3
random effects with lmer() and lme(), three random factors
Hi, all,
I have a question about random effects model. I am dealing with a
three-factor experiment dataset. The response variable y is modeled
against three factors: Samples, Operators, and Runs. The experimental
design is as follow:
4 samples were randomly chosen from a large pool of test samples. Each
of the 4 samples was analyzed by 4 operators, randomly selected from a
group of
2005 Jan 05
0
lme, glmmPQL, multiple random effects
Hi all -
R2.0.1, OS X
Perhaps while there is some discussion of lme going on.....
I am trying to execute a glmm using glmmPQL from the MASS libray, using
the example data set from McCullagh and Nelder's (1989, p442) table
14.4 (it happens to be the glmm example for GENSTAT as well). The data
are binary, representing mating success (1,0) for crosses between males
and females from two
2010 Oct 18
1
Crossed random effects in lme
Dear all,
I am trying to fit a model with crossed random effects using lme. In this
experiment, I have been measuring oxygen consumption (mlmin) in bird
nestlings, originating from three different treatments (treat), in a
respirometer with 7 different channels (ch). I have also measured body mass
(mass) for these birds.
id nest treat year mlmin mass ch hack
1EP51711 17
2003 Jul 01
1
crossed random effects
Hi,
I have a data set on germination and plant growth with
the following variables:
dataset=fm
mass (response)
sub (fixed effect)
moist (fixed effect)
pop (fixed effect)
mum (random effect nested within population)
iheight (covariate)
plot (random effect- whole plot factor for split-plot
design).
I want to see if moist or sub interacts with mum for
any of the pops, but I am getting an error
2004 Feb 16
1
nlme_crossed AND nested random effects
Dear R-help group,
How can I define a lme with 3 factors(a,b,c), where c is nested in b,
and a is crossed with b/c?
I think that:
lme(response ~ ..., data = Data,
random = pdBlocked(list(pdIdent(~ a - 1), pdIdent(~ b - 1))))
is one part of the answer and:
lme(response~..., data=Data, random=~1|b/c)
is the other part of the answer but how can I combine them??
Could anybody please help
2003 Sep 25
0
mixing nested and crossed factors using lme
Hi all,
I have an experiment where 5 raters assessed the quality of 24 web sites. (each rater rated each site once). I want to come up with a measure of reliability of the ratings for the web sites ie to what extent does each rater give the same (or similar) rating to each web site. My idea was to fit a random effects model using lme and from that, calculate the intraclass correlation as a
2006 Feb 07
0
lme and Assay data: Test for block effect when block is systematic - anova/summary goes wrong
Consider the Assay data where block, sample within block and dilut within block is random.
This model can be fitted with (where I define Assay2 to get an ordinary data frame rather
than a grouped data object):
Assay2 <- as.data.frame(Assay)
fm2<-lme(logDens~sample*dilut, data=Assay2,
random=list(Block = pdBlocked(list(pdIdent(~1), pdIdent(~sample-1),pdIdent(~dilut-1))) ))
Now, block
2004 Aug 04
1
cross random effects
Dear friends,
I have asked last few days about cross-random effects
using PQL, but I have not receive any answer because
might my question was not clear.
My question was about analysing the salamander mating
data using PQL. This data contain cross-random effects
for (male) and for (female). By opining MASS and lme
library. I wrote this code
sala.glmm <- glmmPQL(fixed=y~WSf*WSM,
2002 Jan 25
0
nested versus crossed random effects
Hi all,
I'm trying to test a repeated measures model with random effects using the
nlme library. Suppose I have two within subjects factors A, B both with
two levels. Using aov I can do:
aov.1 <- aov(y ~ A*B + Error(S/(A+B))
following Pinheiro and Bates I can acheive the analagous mixed-effects
model with:
lme.1 <- lme(y~A*B, random=pdBlocked(list(pdIdent(~1),pdIdent(~A-1),
2005 Sep 29
1
Bug in lmer?
I am relatively new to R so I am not confident enough in what I am doing
to be certain this is a bug. I am running R 2.1.1 on a Windows XP
machine and the lme4 package version 0.98-1. The following code fits the
model I want using the nlme package version 3.1-60.
mltloc$loc <- factor(mltloc$loc)
mltloc$block <- factor(mltloc$block)
mltloc$trt <- factor(mltloc$trt)
Mltloc <-
2005 Feb 08
2
lme4 --> GLMM
hello!
this is a question, how can i specify the random part in the GLMM-call
(of the lme4 library) for compound matrices just in the the same way as
they defined in the lme-Call (of the nlme library). For example
i would just need
random=list(my.Subject=pdBlocked(list(pdIdent(~... , ...),pdIdent(~... ,
...))))
this specification , if i also attach library(nlme) , is not
2005 Feb 08
2
lme4 --> GLMM
hello!
this is a question, how can i specify the random part in the GLMM-call
(of the lme4 library) for compound matrices just in the the same way as
they defined in the lme-Call (of the nlme library). For example
i would just need
random=list(my.Subject=pdBlocked(list(pdIdent(~... , ...),pdIdent(~... ,
...))))
this specification , if i also attach library(nlme) , is not
2012 Jan 23
2
model non-nested random effects in nlme library
Hello all,
In lme4 if you want to model two non-nested random effects you code it like
this:
mod1 <- lmer(y~x + (1|randomvar1) + (1|randomvar2))
How would you go about to model something similar in nlme?
In my database I have two variables for which I have repeated measures, lets
call them "individual" and "year".
But none of the "individuals" were measured in
2004 Aug 05
1
cross random effects (more information abuot the data)
Dear friends,
I have asked last few days about cross-random effects
using PQL, but I have not receive any answer because
might my question was not clear.
My question was about analysing the salamander mating
data using PQL. This data contain cross-random effects
for (male) and for (female). By opining MASS and lme
library. I wrote this code
sala.glmm <- glmmPQL(fixed=y~WSf*WSM,
2005 Dec 09
1
lmer for 3-way random anova
I have been using lme from nlme to do a 3-way anova with all the effects treated as random. I was wondering if someone could direct me to an example of how to do this using lmer from lme4.
I have 3 main effects, tim, trt, ctr, and all the interaction effects tim*trt*ctr. The response variable is ge.
Here is my lme code:
dat <-
2003 May 12
1
update.lme trouble (PR#2985)
Try this
data(Assay)
as1 <- lme(logDens~sample*dilut, data=Assay,
random=pdBlocked(list(
pdIdent(~1),
pdIdent(~sample-1),
pdIdent(~dilut-1))))
update(as1,random=pdCompSymm(~sample-1))
update(as1,random=pdCompSymm(~sample-1))
update(as1,random=pdCompSymm(~sample-1))
update(as1,random=pdCompSymm(~sample-1))
I'm
2006 Apr 20
1
A question about nlme
Hello,
I have used nlme to fit a model, the R syntax is like
fmla0<-as.formula(paste("~",paste(colnames(ldata[,9:13]),collapse="+"),"-1"))
> fmla1<-as.formula(paste("~",paste(colnames(ldata[,14:18]),collapse="+"),"-1"))
>