Displaying 20 results from an estimated 116 matches for "dendf".
2004 Aug 27
2
degrees of freedom (lme4 and nlme)
...lme4 and nlme, more specifically in the denominator
degrees of freedom. I used data Orthodont for the two
packages. The commands used are below.
require(nlme)
data(Orthodont)
fm1<-lme(distance~age+ Sex,
data=Orthodont,random=~1|Subject, method="REML")
anova(fm1)
numDF DenDF F-value p-value
(Intercept) 1 80 4123.156 <.0001
age 1 80 114.838 <.0001
Sex 1 25 9.292 0.0054
The DenDF for each fixed effect is 80, 80 and 25.
Using the package lme4:
require(lme4)
data(Orthodont)
fm2<-lme(distance~age+ Sex,
da...
2002 Dec 15
2
Interpretation of hypothesis tests for mixed models
...lme(y ~ Trt, random = list(Subj = pdDiag(~ Trt)))
> fm2 <- lme(y ~ trt, random = ~ 1 | Subj/Trt)
These models seem to correspond to the same situation. Both have two
variance components (subject and treatment within subject). However,
they result in different denominator degrees of freedom (denDF) of the
F-statistic for a (fixed-effect) test for treatment. For the case of few
subjects and many observations per subject-treatment combination, denDF
will be much larger for fm1 (denDF = k*2*n-k-1) than for fm2 (denDF =
k-1).
What is the essential difference in the nature of random effects for...
2006 Feb 07
1
post-hoc comparisons following glmm
Dear R community,
I performed a generalized linear mixed model using glmmPQL (MASS
library) to analyse my data i.e : y is the response with a poisson
distribution, t and Trait are the independent variables which are
continuous and categorical (3 categories C, M and F) respectively, ind
is the random variable.
mydata<-glmmPQL(y~t+Trait,random=~1|ind,family=poisson,data=tab)
Do you think it
2004 Nov 25
1
Error in anova(): objects must inherit from classes
...y + stereotypy,
+ random = ~ 1 | bear, data = learning, family = binomial)
> fm2 <- glmmPQL(choice ~ day + envir + stereotypy,
+ random = ~ 1 | bear, data = learning, family = binomial)
Individually, I get results from anova():
> anova(fm1)
numDF denDF F-value p-value
(Intercept) 1 2032 7.95709 0.0048
day 1 2032 213.98391 <.0001
stereotypy 1 2032 0.42810 0.5130
>
> anova(fm2)
numDF denDF F-value p-value
(Intercept) 1 2031 5.70343 0.0170
day 1 2031 213.21673 <.0001
en...
2012 Feb 14
2
how to test the random factor effect in lme
Hi
I am working on a Nested one-way ANOVA. I don't know how to implement
R code to test the significance of the random factor
My R code so far can only test the fixed factor :
anova(lme(PCB~Area,random=~1|Sites, data = PCBdata))
numDF denDF F-value p-value
(Intercept) 1 12 1841.7845 <.0001
Area 1 4 4.9846 0.0894
Here is my data and my hand calculation.
> PCBdata
Area Sites PCB
1 A 1 18
2 A 1 16
3 A 1 16
4 A 2 19
5 A 2 20
6 A 2 19
7 A...
2005 Mar 09
1
multiple comparisons for lme using multcomp
...> #a friend told me that it is possible to do multiple comparisons for lme
in a simplest way, i.e. :
> anova(lm1,L=c("treatmentcontrol"=1,"treatmentAl200"=-1))
F-test for linear combination(s)
treatmentAl200 treatmentcontrol
-1 1
numDF denDF F-value p-value
1 1 12 2.538813 0.1371
> anova(lm1,L=c("treatmentcontrol"=1,"treatmentAl400"=-1))
F-test for linear combination(s)
treatmentAl400 treatmentcontrol
-1 1
numDF denDF F-value p-value
1 1 12 17.30181 0.0013...
2006 Feb 23
2
Strange p-level for the fixed effect with lme function
...bjects within Experiments, but it is
expected to have much slower RT (reaction time) in the second
experiment, since the task is more complex, so it would not make much
sense. That is why I kept analyses separated:
(A) lme(RT ~ F2 + MI, random =~ 1 | Subject, data = exp1)
ANOVA:
numDF denDF F-value p-value
(Intercept) 1 1379 243012.61 <.0001
F2 1 1379 47.55 <.0001
MI 1 1379 4.69 0.0305
Fixed effects: RT ~ F2 + MI
Value Std.Error DF t-value p-value
(Intercept) 6.430962 0.03843484 1379 167.32118 0.0000
F2...
2009 Apr 05
4
extract the p value of F statistics from the lm class
...ms" "residuals"
[4] "coefficients" "aliased" "sigma"
[7] "df" "r.squared" "adj.r.squared"
[10] "fstatistic" "cov.unscaled"
x$fstatistic
value numdf dendf
72.04064 1.00000 31.00000
But can not find the p value of F statistics.
Thanks
Ted
--
View this message in context: http://www.nabble.com/extract-the-p-value-of-F-statistics-from-the-lm-class-tp22891475p22891475.html
Sent from the R help mailing list archive at Nabble.com.
2003 Apr 09
1
[OFF] Nested or not nested, this is the question.
...in a nested design, OK?
I need to know:
the species are different in proportion?
the size affect the species's proportion?
existe interaction between size and species?
I make the analysis.
> m.lme <- lme(nsp/tot~size*specie,random=~1|size/specie)
> anova(m.lme)
numDF denDF F-value p-value
(Intercept) 1 16 374.7121 <.0001
size 1 2 37.8683 0.0254
specie 1 2 18.2036 0.0508
size:specie 1 2 9.3203 0.0926
>
This is the correct mean to make this analysis?
or
> m.lme <- lme(nsp/tot~size*specie,random=~1|plot...
2004 Nov 26
1
help with glmmPQL
...stereotypy,
+ random = ~ 1 | bear, data = learning, family = binomial)
> fm2 <- glmmPQL(choice ~ day + envir + stereotypy,
+ random = ~ 1 | bear, data = learning, family = binomial)
Individually, I get results from anova():
> anova(fm1)
numDF denDF F-value p-value
(Intercept) 1 2032 7.95709 0.0048
day 1 2032 213.98391 <.0001
stereotypy 1 2032 0.42810 0.5130
>
> anova(fm2)
numDF denDF F-value p-value
(Intercept) 1 2031 5.70343 0.0170
day 1 2031 213.21673 <.0001
e...
2007 Nov 01
2
F distribution from lme()?
...Value Std.Error DF t-value p-value
(Intercept) 24.937897 6.662475 11 3.743038 0.0032
kjday 0.108143 0.152540 7 0.708945 0.5013
treat3 -1.506605 0.485336 7 -3.104254 0.0172
#generating an anova table to get the F-distribution
> anova(incub.lme2)
numDF denDF F-value p-value
(Intercept) 1 11 1176.6686 <.0001
kjday 1 7 5.7060 0.0483
treat 1 7 9.6364 0.0172
>
--
View this message in context: http://www.nabble.com/F-distribution-from-lme%28%29--tf4729757.html#a13524346
Sent from the R help mailing list...
2006 Jul 08
1
denominator degrees of freedom and F-values in nlme
...inomial distribution, estimating theta based upon a glm
without individual as a random effect). My data set will not be
balanced, with varying numbers of measurements taken on different
individuals and some individuals have no weight measures just a
morphological type.
My output:
denDF numberdf
Intercept 495
weight 232 1
horn type 495 1
horn type:age 232 4
So my question is where do these denDF come from and how are they
calculated? I wish to then test significane of these fixed effects and
can get F-ratio's and P-values but are these ap...
2003 Jul 27
2
continuous independent variable in lme
...ls for the two other lines so I have set the
following contrasts for lines:
[,1] [,2] [,3]
18 1 0 1
25 -1 0 1
l 0 1 -1
s 0 -1 -1
If I do the following:
mod1<-lme(area ~ line * temp, random = ~1|replicate/temp, mydata)
anova(mod1)
I get:
numDF denDF F-value p-value
(Intercept) 1 336 41817.83 <.0001
line 3 8 14.38 0.0014
temp 1 8 338.21 <.0001
line:temp 3 8 0.62 0.6211
I have a significant effect of selection line. Eyeballing the
interction.plot, it is clear the the line called...
2007 Jul 25
0
DF and intercept term meaning for mixed (lme) models
Hi,
I am using the lme package to fit mixed effects models to a set of data.
I am having a difficult time understanding the *meaning* of the numDF (degrees
of freedom in the numerator), denDF (DF in the denomenator), as well as the
Intercept term in the output.
For example:
I have a groupedData object called 'Soil', and am fitting an lme model as
follows:
## fit a simple model
# errors partitioned among replicates
fit1 <- lme(
? ?log(ksat) ~ log(conc) + ordered(sar) + so...
2005 Jan 03
1
different DF in package nlme and lme4
Hi all
I tried to reproduce an example with lme and used the Orthodont
dataset.
library(nlme)
fm2a.1 <- lme(distance ~ age + Sex, data = Orthodont, random = ~ 1 | Subject)
anova(fm2a.1)
> numDF denDF F-value p-value
> (Intercept) 1 80 4123.156 <.0001
> age 1 80 114.838 <.0001
> Sex 1 25 9.292 0.0054
or alternatively (to get the same result)
fm2a.2 <- lme(distance ~ age + Sex, data = Orthodont, random = list(Subject = ~ 1))
anova(f...
2007 Jun 25
1
degrees of freedom in lme
...20.576 0.0002855 ***
Residuals 10 426.53 42.65
---
Signif. codes: 0 ?***? 0.001 ?**? 0.01 ?*? 0.05 ?.? 0.1 ? ? 1
Error: Within
Df Sum Sq Mean Sq F value Pr(>F)
Residuals 36 33.287 0.925
> anova(lme(fixed=score~Machine,random=~1|Worker/Machine,data=Machines))
numDF denDF F-value p-value
(Intercept) 1 36 773.5709 <.0001
Machine 2 10 20.5762 3e-04
No problem here: the results are essentially the same, which is expected. Now
I turn to an ANCOVA with a random grouping factor.
> data(Orthodont)
> OrthoFem <- Orthodont[Orthodont$Se...
2008 Feb 26
2
AIC and anova, lme
...46 0.43
The usual conclusion would be that the two models are equivalent and to
keep the null model for parsimony (!).
However, an anova shows that the variable 'log(1e-04 + transat)' is
significantly different from 0 in model 2 (lmmedt9)
> anova(lmmedt9)
numDF denDF F-value p-value
(Intercept) 1 20 289.43109 <.0001
log(1e-04 + transat) 1 20 31.18446 <.0001
Has anyone an opinion about what looks like a paradox here ?
Patrick
2005 Jul 18
1
Nested ANOVA with a random nested factor (how to use the lme function?)
...s 40 881875 22047
I have tried the following lme function to specify that Site is random:
> lme1 <- lme(sp~Location, random=~1|Site, data=mavric)
> lme2 <- lme(sp~Location, random=~1|Location/Site, data=mavric)
> anova(lme1)
numDF denDF F-value p-value
(Intercept) 1 40 3.418077 0.0719
Location 4 5 1.152505 0.4294
This gives me the correct F-value for Location from
MSLocation/MSLocation:Transect, but the p-value doesn't seem to be
correct (by my calculations in Microsoft Excel it should be 0.345)...
2005 Apr 12
1
lme problem
...0.19
0.848
bstime:typeSnow Cap 0.9 0.4 24 2.25
0.034
However in Milliken & Johnson all df are 23. Values (estimates) are almost
identical, but there are some small differences in SE and t.
Using
anova(LME.1)
I obtain
numDF denDF F-value p-value
type 6 0 18.19 NaN
bstime:type 6 24 4.04 0.0061
but in the book it is:
numDF denDF F-value p-value
type...
2019 Jan 17
3
long-standing documentation bug in ?anova.lme
...When only one fitted model object is present, a data frame with
the sums of squares, numerator degrees of freedom, denominator
degrees of freedom, F-values, and P-values
The output of
fm1 <- lme(distance ~ age, data = Orthodont) # random is ~ age
anova(fm1)
gives columns
numDF denDF F-value p-value
-- i.e. the sums of squares aren't there! (For fairly good reasons; lme
doesn't actually compute them internally, and it might not always be
straightforward to compute them, for more complex models. They would
mostly be useful for comparison with simpler, method-of-momen...