Re: [R] ANOVA: Factorial designs with a separate control

2007-08-15 Thread Charles C. Berry
Lamac, The ANOVA shown in 'pamph14' may not be suitable for your data. If the replicates are separate experiments or blocks, you will need to become familiar with the nlme package and the lme function in it. ( Your labelling of replicates suggests that this is the case, viz. no A==1 & B == 3

[R] ANOVA: Factorial designs with a separate control

2007-08-14 Thread lamack lamack
Dear all, I would like to run in R the anova showed in the following pamphlet. http://www.for.gov.bc.ca/hre/biopamph/pamp14.pdf For A = 0 and B =0 I have de control group. Best regards. AB replication response 0 0 1 24 0 0

Re: [R] ANOVA: Does a Between-Subjects Factor belong in the Error Term?

2007-07-09 Thread Christophe Pallier
On 7/9/07, Alex Baugh <[EMAIL PROTECTED]> wrote: > > I am executing a Repeated Measures Analysis of Variance with 1 DV > (LOCOMOTOR > RESPONSE), 2 Within-Subjects Factors (AGE, ACOUSTIC CONDITION), and 1 > Between-Subjects Factor (SEX). > > Does anyone know whether the between-subjects factor (SEX

Re: [R] ANOVA: Does a Between-Subjects Factor belong in the Error Term?

2007-07-09 Thread Peter Dalgaard
Alex Baugh wrote: > I am executing a Repeated Measures Analysis of Variance with 1 DV (LOCOMOTOR > RESPONSE), 2 Within-Subjects Factors (AGE, ACOUSTIC CONDITION), and 1 > Between-Subjects Factor (SEX). > > Does anyone know whether the between-subjects factor (SEX) belongs in the > Error Term of th

[R] ANOVA: Does a Between-Subjects Factor belong in the Error Term?

2007-07-09 Thread Alex Baugh
I am executing a Repeated Measures Analysis of Variance with 1 DV (LOCOMOTOR RESPONSE), 2 Within-Subjects Factors (AGE, ACOUSTIC CONDITION), and 1 Between-Subjects Factor (SEX). Does anyone know whether the between-subjects factor (SEX) belongs in the Error Term of the aov or not? And if it does

Re: [R] ANOVA non-sphericity test and corrections (eg, Greenhouse-Geisser)

2007-06-25 Thread John Wilkinson
Darren, Further to Peter Dalgaard's help; Take a look at the example in --- library(car) ?Anova # note upper case 'A' The example in the Anova help page following the --- ## a multivariate linear model for repeated-measures data ## See ?OBrienKaiser for a description of the data set used in

Re: [R] ANOVA non-sphericity test and corrections (eg, Greenhouse-Geisser)

2007-06-25 Thread Simon Blomberg
On Mon, 2007-06-25 at 17:53 +1000, Simon Blomberg wrote: > If you use lme, you can fit a general correlation structure to the > within-subject data, and compare the fit to a model assuming > uncorrelated within-subjects errors. That should tell you whether your > data are ... correlated... (damn e

Re: [R] ANOVA non-sphericity test and corrections (eg, Greenhouse-Geisser)

2007-06-25 Thread Simon Blomberg
If you use lme, you can fit a general correlation structure to the within-subject data, and compare the fit to a model assuming uncorrelated within-subjects errors. That should tell you whether your data are Aren't the G-G and H-F corrections only approximate fixes? Surely it is better to work with

Re: [R] ANOVA non-sphericity test and corrections (eg, Greenhouse-Geisser)

2007-06-24 Thread Peter Dalgaard
DarrenWeber wrote: > I'm an experimental psychologist and when I run ANOVA analysis in > SPSS, I normally ask for a test of non-sphericity (Box's M-test). I > also ask for output of the corrections for non-sphericity, such as > Greenhouse-Geisser and Huhn-Feldt. These tests and correction factors

[R] ANOVA non-sphericity test and corrections (eg, Greenhouse-Geisser)

2007-06-24 Thread DarrenWeber
I'm an experimental psychologist and when I run ANOVA analysis in SPSS, I normally ask for a test of non-sphericity (Box's M-test). I also ask for output of the corrections for non-sphericity, such as Greenhouse-Geisser and Huhn-Feldt. These tests and correction factors are commonly used in the

Re: [R] anova on data means

2007-06-21 Thread Moshe Olshansky
An ugly solution (but which works) would be something like this (assuming that d is a data.frame with 4 columns named Tank, Trt, Fish, Size): x <-1:12 for (i in 1:12) x[i] <- mean(d$Size[d$Tank == i]) Regards, Moshe Olshansky --- Ronaldo Reis Junior <[EMAIL PROTECTED]> wrote: > Em Quinta 21 Jun

Re: [R] anova on data means

2007-06-21 Thread Peter Dalgaard
Ronaldo Reis Junior wrote: > Em Quinta 21 Junho 2007 16:56, Thomas Miller escreveu: > >> I am transitioning from SAS to R and am struggling with a relatively simple >> analysis. Have tried Venables and Ripley and other guides but can't find a >> solution. >> >> I have an experiment with 12 tank

Re: [R] anova on data means

2007-06-21 Thread Ronaldo Reis Junior
Em Quinta 21 Junho 2007 16:56, Thomas Miller escreveu: > I am transitioning from SAS to R and am struggling with a relatively simple > analysis. Have tried Venables and Ripley and other guides but can't find a > solution. > > I have an experiment with 12 tanks. Each tank holds 10 fish. The 12 ta

[R] anova on data means

2007-06-21 Thread Thomas Miller
I am transitioning from SAS to R and am struggling with a relatively simple analysis. Have tried Venables and Ripley and other guides but can't find a solution. I have an experiment with 12 tanks. Each tank holds 10 fish. The 12 tanks have randomly assigned one of 4 food treatments - S(tarve),

[R] anova(lme)

2007-06-06 Thread Johannes Mühe
I'd like to do 2 ANOVA with repeated measurement. First:response = "AS" 1.within-factor = "modal" 2.within-factor = "ref" (all stairs of the factors are repeated measured) so that random = "vp" I did it like this: (anova(lme(AS~modal*ref,

Re: [R] Anova Test

2007-05-15 Thread John Kane
have a look at the examples in ?aov. Also not that npk is a dataframe in this example --- CrazyJoe <[EMAIL PROTECTED]> wrote: > > Thank you Guys. > > Let say that from Test1 to control i have multiple > data > > Tester > Test1 Test2 Test3 Test4 Control > 20 25 1510

[R] Anova F-Test

2007-05-15 Thread CrazyJoe
Basically, i have 4 tests and 1 control. For example. Tester Test1 Test2 Test3 Test4 20 25 1510 30 45 10 15 .. .. .. .. .. .. .. .. 15 23 1345 The inference is at alpha=0

Re: [R] Anova Test

2007-05-15 Thread Christophe Pallier
If your data is inside a data.frame names 'a' with data from each group in a different columns,..., you can use "stack" and perform the anova with: l <- aov(values~ind,data=stack(a)) anova(l) Christophe Pallier On 5/15/07, CrazyJoe <[EMAIL PROTECTED]> wrote: > > > Thank you Guys. > > Let say t

Re: [R] Anova Test

2007-05-15 Thread Petr PIKAL
[EMAIL PROTECTED] napsal dne 15.05.2007 17:32:35: > > Thank you Guys. > > Let say that from Test1 to control i have multiple data > > Tester > Test1 Test2 Test3 Test4 Control > 20 25 1510 17 > . . . . . > . . .

Re: [R] Anova Test

2007-05-15 Thread CrazyJoe
Thank you Guys. Let say that from Test1 to control i have multiple data Tester Test1 Test2 Test3 Test4 Control 20 25 1510 17 . . . . . . . . . . 40 20 1535 45 Is this t

Re: [R] Anova Test

2007-05-15 Thread Ben Bolker
CrazyJoe hotmail.com> writes: > > I am very new to R. I am trying to perform an Anova Test and see if it > differs or not. > > Basically, i have 4 tests and 1 control. > > Tester > Test1 Test2 Test3 Test4 Control > 20 25 1510 17 > You can't make any inferences

[R] Anova Test

2007-05-15 Thread CrazyJoe
Hi, I am very new to R. I am trying to perform an Anova Test and see if it differs or not. Basically, i have 4 tests and 1 control. Tester Test1 Test2 Test3 Test4 Control 20 25 1510 17 The inference is at alpha=0.05. they are all independent. I am trying to find if

[R] Anova

2007-05-10 Thread Iasonas Lamprianou
Doea anyone know how to compute components of variance analysis? For example, I have the score of pupils on a test. Each pupil belongs to a school and within each school I may have several classes? How can I estimate the variance of the pupils, schools, classes and the errror variance? Any exa

Re: [R] ANOVA results in R conflicting with results in ot her software packages

2007-04-26 Thread Dieter Menne
Simon Blomberg uq.edu.au> writes: . > I won't discuss the dangers of "types" of sums of squares and different > contrast codings. That would be tempting the wrath of the gods. See > section 7.18 in the R FAQ. John Fox's "Companion" book also has a brief > discussion (p. 140). And

Re: [R] ANOVA results in R conflicting with results in other software packages

2007-04-25 Thread Simon Blomberg
R uses "treatment" contrasts for factors (ie 0/1 coding) by default. Systat is using "sum" (ie sum to zero) contrasts: Try this: options(contrasts=c("contr.sum", "contr.poly") lm(maladapt~host*increase*size2)->fm Anova(fm, type="III") I won't discuss the dangers of "types" of sums of squares and

Re: [R] ANOVA results in R conflicting with results in other software packages

2007-04-25 Thread Richard M. Heiberger
It looks from your tables that you have the same residual in both programs, suggesting that the arithmetic is correct. The terms are in a different order. Since anova() gives sequential sums of squares (Type I), the numerical values depend on the order. Force both programs to use the same order f

[R] ANOVA results in R conflicting with results in other software packages

2007-04-25 Thread Daniel Bolnick
Hi, I'm wrestling with an analysis of a dataset, which I previously analyzed in SYSTAT, but am now converting to R and was doing a re-analysis. I noticed, however, that the same model yields different results (different sums of squares) from the two programs. I first thought this might be beca

Re: [R] R Anova

2007-04-25 Thread Uwe Ligges
Keizer_61 wrote: > I am really struggling with this question. > > Three students take part of an experiment. > > student smoking non-smokingcancer > 110.5 7.5 6.5 > 2 9.5 6.5 8.4 > 3 8.5 7.

[R] R Anova

2007-04-24 Thread Keizer_61
inferences is .05 we need to conduct Anova and have a inference of .05. How do you enter this in R? How do you calculate the F-test using R for this if we have smoking, non-smoking and cancer all equal. any suggestions? thanks -- View this message in context: http://www.nabble.com/R-Anova

Re: [R] ANOVA and confidence intervals plot

2007-04-02 Thread Max Manfrin
On 02 Apr 2007, at 04:40, Richard M. Heiberger wrote: I would like to obtain for each factor of my anova model the "response variable vs factor" plot with means and 95% Tukey HSD intervals. I believe you are asking for the multiple comparisons plots from the multcomp package. librar

Re: [R] anova-interaction

2007-04-01 Thread Richard M. Heiberger
I continue with your example dados$mat <- factor(dados$mat) dados$temp <- factor(dados$temp) contrasts(dados$temp) contrasts(dados$temp) <- contr.poly(3) amt <- aov(time ~ mat*temp, data=dados) summary(amt) summary.lm(amt) summary(amt, split=list(mat=list(mat2=1, mat3=2),

Re: [R] ANOVA and confidence intervals plot

2007-04-01 Thread Richard M. Heiberger
> I would like to obtain for each factor of my anova model the > "response variable vs factor" plot with means and 95% Tukey HSD > intervals. I believe you are asking for the multiple comparisons plots from the multcomp package. The example below is an extension of one of the examples i

[R] ANOVA and confidence intervals plot

2007-03-30 Thread Max Manfrin
Dear *, I would like to obtain for each factor of my anova model the "response variable vs factor" plot with means and 95% Tukey HSD intervals. I would appreciate any information on how to do that. Cheers

[R] anova-interaction

2007-03-25 Thread Bruno Grimaldo Martinho Churata
HI, I am trying to perform ANOVA with 2 factors: material (3), temperature(3). The interaction is significant. I tried something like, ( summary(avt, split=list("temp:mat"=list("15"=1, "70"=2, "125"=3))) is not correct). Thanks, av <- aov(time ~ mat*temp, data=dados) avt <- aov(time ~ temp/mat)

Re: [R] anova applied to a lme object

2007-03-07 Thread Berta
PROTECTED]> To: "Berta" <[EMAIL PROTECTED]> Cc: Sent: Wednesday, March 07, 2007 5:16 PM Subject: Re: [R] anova applied to a lme object > The variances of the random effects and the residual variances are given > by the summary function. Maybe VarCorr or varcomp gives you th

Re: [R] anova applied to a lme object

2007-03-07 Thread José Rafael Ferrer Paris
The variances of the random effects and the residual variances are given by the summary function. Maybe VarCorr or varcomp gives you the answer you are looking for: library(nlme) library(ape) ?VarCorr ?ape JR El mié, 07-03-2007 a las 13:09 +0100, Berta escribió: > Hi R-users, > > when carrying o

[R] anova applied to a lme object

2007-03-07 Thread Berta
Hi R-users, when carrying out a multiple regression, say lm(y~x1+x2), we can use an anova of the regression with summary.aov(lm(y~x1+x2)), and afterwards evaluate the relative contribution of each variable using the global Sum of Sq of the regression and the Sum of Sq of the simple regression y

Re: [R] ANOVA Table for Full Linear Model?

2007-02-06 Thread Frank E Harrell Jr
Peter Dalgaard wrote: > Jason R. Finley wrote: >> Hello, >> I have spent a good deal of time searching for an answer to this but >> have come up empty-handed; I apologize if I missed something that is >> common knowledge. >> >> I am trying to figure out how to get an ANOVA table that shows the

Re: [R] ANOVA Table for Full Linear Model?

2007-02-06 Thread Peter Dalgaard
Jason R. Finley wrote: > Hello, > I have spent a good deal of time searching for an answer to this but > have come up empty-handed; I apologize if I missed something that is > common knowledge. > > I am trying to figure out how to get an ANOVA table that shows the > sum of squares. degrees of

Re: [R] ANOVA Table for Full Linear Model?

2007-02-06 Thread talepanda
summary.lm tells you F, df, and p value. try: summary(regression9) On 2/6/07, Jason R. Finley <[EMAIL PROTECTED]> wrote: > Hello, > I have spent a good deal of time searching for an answer to this but > have come up empty-handed; I apologize if I missed something that is > common knowledge. > >

[R] ANOVA Table for Full Linear Model?

2007-02-05 Thread Jason R. Finley
Hello, I have spent a good deal of time searching for an answer to this but have come up empty-handed; I apologize if I missed something that is common knowledge. I am trying to figure out how to get an ANOVA table that shows the sum of squares. degrees of freedom, etc, for the full model ve

Re: [R] ANOVA in Randomized-complete blocks design

2006-11-02 Thread Simon Blomberg
January Weiner wrote: > Ops, sorry. > > OK, as you see, I am going through S&R and doing the examples using R. > I have a further question, on the nested ANOVA example from Box 10.1 > (mosquito female wing lengths). I made sure that the data is correct > :-) (data below). > > I am not sure how to

Re: [R] ANOVA in Randomized-complete blocks design

2006-11-02 Thread Richard M. Heiberger
my apologies. anova() doesn't work on class "aovlist". It is necessary to use summary(). They are similar for "aov", but not for "aovlist". wing <- read.table("tmp.dat", header=TRUE) wing.aov <- aov( wing ~ cage + Error(cage:female), data=wing ) summary(wing.aov)

Re: [R] ANOVA in Randomized-complete blocks design

2006-11-02 Thread January Weiner
> ## tmp.dat is your data in a file. > > wing <- read.table("tmp.dat", header=TRUE) > wing.aov <- aov( wing ~ cage + Error(cage:female), data=wing ) > anova(wing.aov) Thanks for the answer! However, I am not able to run the above: > wing <- read.table("nested.txt", header=TRUE) > names(wing) [1]

Re: [R] ANOVA in Randomized-complete blocks design

2006-11-02 Thread Richard M. Heiberger
## tmp.dat is your data in a file. wing <- read.table("tmp.dat", header=TRUE) wing.aov <- aov( wing ~ cage + Error(cage:female), data=wing ) anova(wing.aov) ## Notice that at full precision, the R values of the mean squares ## give the number you are looking for 332.84 / 1.3017 _

Re: [R] ANOVA in Randomized-complete blocks design

2006-11-02 Thread January Weiner
Ops, sorry. OK, as you see, I am going through S&R and doing the examples using R. I have a further question, on the nested ANOVA example from Box 10.1 (mosquito female wing lengths). I made sure that the data is correct :-) (data below). I am not sure how to create in R a Model II nested ANOVA.

Re: [R] ANOVA in Randomized-complete blocks design

2006-11-02 Thread Simon Blomberg
You have mis-transcribed the data: SeriesGenotypeWeight 1pb0.986 3bb0.829 anova(aov(weight ~ series + genotype, data=dat)) gives the correct results when compared to S&R. Cheers, Simon. January Weiner wrote: > Dear all, > > I am

[R] ANOVA in Randomized-complete blocks design

2006-11-02 Thread January Weiner
Dear all, I am trying to repeat an example from Sokal and Rohlfs "Biometry" -- Box 11.4, example of a randomized-complete-blocks experiment. The data is fairly simple: series genotype weight 1 pp 0.958 1 pb 0.985 1 bb 0.925 2 pp 0.971 2 pb 1.051

[R] ANOVA and Levene's test in nested model

2006-10-17 Thread Emilia Pippola
Dear All, I sent already before a message concerning Levene's test in nested model, but I didn't get any answer. Optimistically I hope to get an answer this time. I also point a new question related to the whole model, because I haven't find any sure answer if I am analysing it in a suitable way

[R] ANOVA with 3 factors

2006-10-14 Thread A Ezhil
Hi, I am trying to perform ANOVA with 3 factors: individuals (3), time(3) and treatment(2). I tried something like, fit <- lm(dat ~ ind*time*treat) res <- anova(fit) Is this the correct approach? Is there any R pacakge to calculate P values using permutation for ANOVA with 3 factors? Thanks in

Re: [R] ANOVA in R

2006-09-14 Thread Russell Compton
ost useful. Thanks again, Russell Compton -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Peter Dalgaard Sent: 14 September 2006 10:26 To: Andrew Robinson Cc: Russell Compton; r-help@stat.math.ethz.ch Subject: Re: [R] ANOVA in R Andrew Robinson <[EM

Re: [R] ANOVA in R

2006-09-14 Thread Peter Dalgaard
Andrew Robinson <[EMAIL PROTECTED]> writes: > Try > > test <- data.frame(day.1=c(2,3,3,6,1), > day.4=c(7,2,4,6,3), > day.8=c(2,8,7,8,4)) > > test > > test.long <- reshape(test, direction="long", > varying=c("day.1","day.4","day.8"), > v.names="response", > ti

Re: [R] ANOVA in R

2006-09-14 Thread Andrew Robinson
Try test <- data.frame(day.1=c(2,3,3,6,1), day.4=c(7,2,4,6,3), day.8=c(2,8,7,8,4)) test test.long <- reshape(test, direction="long", varying=c("day.1","day.4","day.8"), v.names="response", timevar="day", times=names(test)) test.long$day <- f

[R] ANOVA in R

2006-09-14 Thread Russell Compton
Despite having used R on a daily basis for the past two years, I'm encountering some difficulty performing an ANOVA on my data. What I'm trying to do is the following: Given data such as: Day 1Day 4Day 8 2 7 2 3 2 8 3 4

[R] ANOVA in R

2006-09-14 Thread Russell Compton
Despite having used R on a daily basis for the past two years, I’m encountering some difficulty performing an ANOVA on my data. What I’m trying to do is the following:   Given data such as:   Day 1    Day 4    Day 8 2  7  2 3  2  8  3  4  7 6

Re: [R] anova for the objects of list

2006-06-05 Thread Hai Lin
Dear R experts, Sorry for the previous email. I just figured it out myself. I would welcome other solutions. Thanks. Kevin my.anova <- sapply(names(my.x), function(x) { anova(my.x[[x]], my.x1[[x]])

[R] anova for the objects of list

2006-06-05 Thread Hai Lin
Dear R experts, I have two list objects from runing lme model for each subjects. And my.x is the full model with all terms I am interested in and my.x1 is the null model with only intercept. I am trying to compare two models at each subject level. (Doing anova(my.x[[1]], my.x1[[1]]) is to produce

Re: [R] anova statistics in lmer

2006-05-15 Thread Berton Gunter
ginal Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Doran, Harold > Sent: Monday, May 15, 2006 9:15 AM > To: Diego Vázquez; r-help@stat.math.ethz.ch > Subject: Re: [R] anova statistics in lmer > > The issue is not unresolved within lmer, b

Re: [R] anova statistics in lmer

2006-05-15 Thread Doran, Harold
PROTECTED] On Behalf Of Diego Vázquez > Sent: Monday, May 15, 2006 11:53 AM > To: r-help@stat.math.ethz.ch > Subject: [R] anova statistics in lmer > > Dear list members, > > I am new to R and to the R-help list. I am trying to perform > a mixed-model analysis using the lme

[R] anova statistics in lmer

2006-05-15 Thread Diego Vázquez
Dear list members, I am new to R and to the R-help list. I am trying to perform a mixed-model analysis using the lmer() function. I have a problem with the output anova table when using the anova() function on the lmer output object: I only get the numerator d.f., the sum of squares and the mean s

[R] ANOVA & BOOTSTRAP

2006-03-29 Thread Romain . Mayor
Hello, I'm working on 30 natural populations of Aster amellus L. a threatened plant species. My aim is to see if the population size influence on several fitness trait. I build a multi-factorial ANOVA. The independents variables are altitude, humidity, soil component, maintenance and populat

[R] ANOVA: Help with SSQ decomposition and contrasts

2006-02-13 Thread Jose Claudio Faria
# Dear R list, # # A have a doubt about SSQ decomposition and contrasts with ANOVAs. # So, I would like a tip from more advanced R users. # Below my data, the basic script and my doubts: # Data r = paste('r', gl(3, 8), sep='') e = paste('e', rep(gl(2, 4), 3), sep='') tra = sort(paste('t', rep

[R] Anova help

2006-01-30 Thread Vasundhara Akkineni
Hello all, I am trying to perform ANOVA on my sample data given below to see if any gene(column 1 stands for gene names) is differentially expressed after subjecting it to the 6 different experiments(columns 2 to 7 are experiments). Gene 14A_U133A_Detection 14B_U133A_Signal 88A_U133A_Si

Re: [R] Anova problem with order of terms in model

2006-01-17 Thread John Fox
> -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Martin Julien > Sent: Tuesday, January 17, 2006 3:34 PM > To: r-help@stat.math.ethz.ch > Subject: [R] Anova problem with order of terms in model > > Hi > I have a linear model and I

Re: [R] Anova problem with order of terms in model

2006-01-17 Thread Berton Gunter
quot;The business of the statistician is to catalyze the scientific learning process." - George E. P. Box > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Martin Julien > Sent: Tuesday, January 17, 2006 12:34 PM > To: r-help@st

[R] Anova problem with order of terms in model

2006-01-17 Thread Martin Julien
anyone can explain what happen or what am I doing wrong ? In R > anova (lm(Y~X.1+X.2)) Analysis of Variance Table Response: Y Df Sum Sq Mean Sq F value Pr(>F) X.1 1 4.0351 4.0351 6.5187 0.01852 X.2 1

Re: [R] anova with models from glmmPQL

2005-10-19 Thread Lorenz . Gygax
> I try to compare some models obtained from glmmPQL. > > model1 <- > glmmPQL(y~red*yellow+I(red^2)+I(yellow^2)+densite8+I(densite8^ > 2)+freq8_4 > +I(freq8_4^2), random=~1|num, binomial); > model2 <- > glmmPQL(y~red*yellow+I(red^2)+I(yellow^2)+densite8+I(densite8^ > 2)+freq8_4 > , random=~1|num,

[R] anova with models from glmmPQL

2005-10-19 Thread Emmanuelle TASTARD
Hi ! I try to compare some models obtained from glmmPQL. model1 <- glmmPQL(y~red*yellow+I(red^2)+I(yellow^2)+densite8+I(densite8^2)+freq8_4 +I(freq8_4^2), random=~1|num, binomial); model2 <- glmmPQL(y~red*yellow+I(red^2)+I(yellow^2)+densite8+I(densite8^2)+freq8_4 , random=~1|num, binomial); ano

Re: [R] anova on binomial LMER objects

2005-09-29 Thread Douglas Bates
The issues with lmer and the analysis of variance are due to its not make appropriate correction for the prior weights vector. If you convert your binomial response to the equivalent number of binary responses you get an appropriate anova table. It's on the "ToDo" list to fix this but a few other

Re: [R] anova on binomial LMER objects

2005-09-29 Thread Alan Cobo-Lewis
On Wed, 28 Sep 2005, Robert Bagchi wrote: >>Hi Patrick >> >>thanks for your advice. I have now tried glmmPQL, and it worked fine - >>I'm getting consistent results between plots and models fitted by >>glmmPQL. Plus it allows predict() and resid() which is another advantage >>over lmer at present

Re: [R] anova on binomial LMER objects

2005-09-28 Thread Prof Brian Ripley
On Wed, 28 Sep 2005, Robert Bagchi wrote: Hi Patrick thanks for your advice. I have now tried glmmPQL, and it worked fine - I'm getting consistent results between plots and models fitted by glmmPQL. Plus it allows predict() and resid() which is another advantage over lmer at present. quick que

Re: [R] anova on binomial LMER objects

2005-09-28 Thread Robert Bagchi
Hi Patrick thanks for your advice. I have now tried glmmPQL, and it worked fine - I'm getting consistent results between plots and models fitted by glmmPQL. Plus it allows predict() and resid() which is another advantage over lmer at present. quick question though: why does one need to use PQL

Re: [R] anova on binomial LMER objects

2005-09-26 Thread Prof Brian Ripley
On Mon, 26 Sep 2005, Martin Henry H. Stevens wrote: > Hello all, > 1. Does Matrix 0.98-7 fix any of this? > 2. Assuming "no", how does one acquire Matrix 0.95-13? It is in the Archive on CRAN, e.g. http://cran.r-project.org/src/contrib/Archive/M/Matrix_0.95-13.tar.gz > Cheers, and thank you kin

Re: [R] anova on binomial LMER objects

2005-09-26 Thread Martin Henry H. Stevens
Hello all, 1. Does Matrix 0.98-7 fix any of this? 2. Assuming "no", how does one acquire Matrix 0.95-13? Cheers, and thank you kindly in advance, Hank On Sep 26, 2005, at 9:05 AM, Douglas Bates wrote: > On 9/25/05, Horacio Montenegro <[EMAIL PROTECTED]> wrote: > >> >> Hi Spencer and Robert, >

Re: [R] anova on binomial LMER objects

2005-09-26 Thread Douglas Bates
On 9/25/05, Horacio Montenegro <[EMAIL PROTECTED]> wrote: > > Hi Spencer and Robert, > > I have found the same behaviour, but only for lme4 > and Matrix after the 0.96 release. lme4 0.95-10 and > Matrix 0.95-13 releases gave "sensible" results. This > could be an introduced bug, or a solved

Re: [R] anova on binomial LMER objects

2005-09-25 Thread Horacio Montenegro
Hi Spencer and Robert, I have found the same behaviour, but only for lme4 and Matrix after the 0.96 release. lme4 0.95-10 and Matrix 0.95-13 releases gave "sensible" results. This could be an introduced bug, or a solved bug - you should ask Prof. Bates. hope this helps, cheers,

Re: [R] anova on binomial LMER objects

2005-09-25 Thread Spencer Graves
I agree: Something looks strange to me in this example also; I have therefore copied Douglas Bates and Deepayan Sarkar. You've provided a nice simulation. If either of them have time to look at this, I think they could tell us what is happening here. If you need an answ

[R] anova on binomial LMER objects

2005-09-22 Thread Robert Bagchi
Dear R users, I have been having problems getting believable estimates from anova on a model fit from lmer. I get the impression that F is being greatly underestimated, as can be seen by running the example I have given below. First an explanation of what I'm trying to do. I am trying to fit a

[R] anova for random-intercept lmer

2005-09-19 Thread A Das
Hi, This might be a silly question, but how do I create a pooled model (binomial family) as a baseline for a likelihood-ratio test for a random-intercept lmer model? R won't compare a glm model with an lmer model (or glmmPQL ). Thanks in advance. -Bobby __

Re: [R] ANOVA/aov question

2005-07-25 Thread Prof Brian Ripley
On Mon, 25 Jul 2005 [EMAIL PROTECTED] wrote: > I'm a bit confused about the anova/aov functions. Both seem to rely on > data models, where the relationship between the dependent variables and > the independent variables can be expressed as a formula. In what I am > trying to do, all of my indepe

[R] ANOVA/aov question

2005-07-25 Thread eph1v3t8-rhls6783
I'm a bit confused about the anova/aov functions. Both seem to rely on data models, where the relationship between the dependent variables and the independent variables can be expressed as a formula. In what I am trying to do, all of my independent variables are qualitative, not quantitative.

Re: [R] ANOVA vs REML approach to variance component estimation

2005-06-12 Thread Adaikalavan Ramasamy
Thank you. On Sun, 2005-06-12 at 18:54 -0500, Douglas Bates wrote: > On 6/12/05, Adaikalavan Ramasamy <[EMAIL PROTECTED]> wrote: > > Thank you for confirming this and introducing me to varcomp(). > > > > I have another question that I hope you or someone else can help me > > with. I was trying to

Re: [R] ANOVA vs REML approach to variance component estimation

2005-06-12 Thread Douglas Bates
On 6/12/05, Adaikalavan Ramasamy <[EMAIL PROTECTED]> wrote: > Thank you for confirming this and introducing me to varcomp(). > > I have another question that I hope you or someone else can help me > with. I was trying to generalise my codes for variable measurement > levels and discovered that lme

Re: [R] ANOVA vs REML approach to variance component estimation

2005-06-12 Thread Adaikalavan Ramasamy
Thank you for confirming this and introducing me to varcomp(). I have another question that I hope you or someone else can help me with. I was trying to generalise my codes for variable measurement levels and discovered that lme() was estimating the within group variance even with a single measure

Re: [R] ANOVA vs REML approach to variance component estimation

2005-06-10 Thread Chuck Cleland
They look fine to me. Also, note varcomp() in the ape package and VarCorr() in the nlme package. I think in this case the ANOVA estimate of the intercept variance component is negative because the true value is close to zero. > y <- c( 2.2, -1.4, -0.5, # animal 1 +-0.3, -2.1, 1.

[R] ANOVA vs REML approach to variance component estimation

2005-06-10 Thread Adaikalavan Ramasamy
Can anyone verify my calculations below or explain why they are wrong ? I have several animals that were measured thrice. The only blocking variable is the animal itself. I am interested in calculating the between and within object variations in R. An artificial example : y <- c( 2.2, -1.4, -0.5

[R] ANOVA with p-values?

2005-05-11 Thread Christoph Strehblow
Hi List! My name is Christoph Strehblow, i´m from Vienna, Austria, and tried a ANOVA, but couldn´t manage to get an output, i was used to get from SPSS, where i would get a detailed pairwise table, including diff, standard error, p-value, and lwr and upr. in R, i tried a ANOVA with TukeyHSD

RE: [R] Anova - interpretation of the interaction term

2005-04-23 Thread Liaw, Andy
> From: [EMAIL PROTECTED] > > On 23-Apr-05 [EMAIL PROTECTED] wrote: [snip] > [technical setup snipped] > > >> contrasts(dat$vac_inf) <- ginv(m) > >> gm <- aov(y ~ vac_inf, dat) > >> summary(gm) > > Df Sum Sq Mean Sq F value Pr(>F) > > vac_inf 3 12.1294 4.0431 7.348 0.04190

RE: [R] Anova - interpretation of the interaction term

2005-04-23 Thread Ted Harding
On 23-Apr-05 [EMAIL PROTECTED] wrote: >: -Original Message- >: From: [EMAIL PROTECTED] >: [mailto:[EMAIL PROTECTED] On Behalf Of >: michael watson (IAH-C) >: [...] >: I have a highly significant interaction term. In the context >: of the experiment, this makes sense. I can visualise the d

RE: [R] ANOVA with both discreet and continuous variable

2005-04-22 Thread Bill.Venables
An anonymous enquirer asks: : -Original Message- : From: [EMAIL PROTECTED] : [mailto:[EMAIL PROTECTED] On Behalf Of array chip : Sent: Saturday, 23 April 2005 2:32 PM : To: r-help@stat.math.ethz.ch : Subject: [R] ANOVA with both discreet and continuous variable : : : Hi all, : : I

[R] ANOVA with both discreet and continuous variable

2005-04-22 Thread array chip
Hi all, I have dataset with 2 independent variable, one (x1) is continuous, the other (x2) is a categorical variable with 2 levels. The dependent variable (y) is continuous. When I run linear regression y~x1*x2, I found that the p value for the continuous independent variable x1 changes when diffe

RE: [R] Anova - interpretation of the interaction term

2005-04-22 Thread Bill.Venables
: -Original Message- : From: [EMAIL PROTECTED] : [mailto:[EMAIL PROTECTED] On Behalf Of : michael watson (IAH-C) : Sent: Friday, 22 April 2005 7:47 PM : To: r-help@stat.math.ethz.ch : Subject: [R] Anova - interpretation of the interaction term : : : Hi : : So carrying on my use of

RE: [R] Anova - interpretation of the interaction term

2005-04-22 Thread Ted Harding
On 22-Apr-05 michael watson \(IAH-C\) wrote: > [...] > So from a statistical point of view, I can see exactly why the > interaction term is significant, but what my colleage wants to know is > that WITHIN the vaccinated group, does infection decrease expression > significantly? And within the unva

[R] Anova - interpretation of the interaction term

2005-04-22 Thread michael watson \(IAH-C\)
Hi So carrying on my use of analysis of variance to check for the effects of two factors. It's made simpler by the fact that both my factors have only two levels each, creating four unique groups. I have a highly significant interaction term. In the context of the experiment, this makes sense.

Re: [R] ANOVA model

2005-04-21 Thread Douglas Bates
Street N.R. wrote: Hi, Could someone tell me if this is the correct model syntax for the following dataset: lme(height~treatment+genotype+treatment*genotype,drought,random=~genotyp e) The dataset has two factors: one fixed - treatment, and one random - genotype. I need to test the effect of both fa

RE: [R] ANOVA model

2005-04-21 Thread Doran, Harold
), drought) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Street N.R. Sent: Thursday, April 21, 2005 12:13 PM To: r-help@stat.math.ethz.ch Subject: [R] ANOVA model Hi, Could someone tell me if this is the correct model syntax for the following dataset:

[R] ANOVA model

2005-04-21 Thread Street N.R.
Hi, Could someone tell me if this is the correct model syntax for the following dataset: lme(height~treatment+genotype+treatment*genotype,drought,random=~genotyp e) The dataset has two factors: one fixed - treatment, and one random - genotype. I need to test the effect of both factors to identif

RE: [R] Anova - adjusted or sequential sums of squares?

2005-04-21 Thread Lucke, Joseph F
pril 21, 2005 3:51 AM To: Prof Brian Ripley Cc: r-help@stat.math.ethz.ch Subject: RE: [R] Anova - adjusted or sequential sums of squares? OK, I had no idea I was opening such a pandora's box, but thank you for all of your answers, it's been fascinating reading. This is how far I have go

RE: [R] Anova - adjusted or sequential sums of squares?

2005-04-21 Thread michael watson \(IAH-C\)
type III SS, change my contrast matrices to sum to zero and use drop1(model, .~., test="F") Many thanks Mick -Original Message- From: Prof Brian Ripley [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 16:35 To: michael watson (IAH-C) Cc: Liaw, Andy; r-help@stat.math.ethz.ch Sub

RE: [R] Anova - adjusted or sequential sums of squares? - An example

2005-04-20 Thread Berton Gunter
-Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Ted Harding > Sent: Wednesday, April 20, 2005 8:54 AM > To: michael watson (IAH-C) > Cc: [EMAIL PROTECTED]; r-help@stat.math.ethz.ch > Subject: RE: [R] Anova - adjusted or sequential sums o

  1   2   >