[R] Mixed-design ANOVA: 2 between-subject factors and 1 within-subject factor

From: Floating0914 <ziyonglin_at_gmail.com>
Date: Mon, 09 May 2011 02:48:38 -0700 (PDT)


Dear all,

I am trying to using a mixed-design ANOVA to analyze my data. I have two between subject variables: location (2 different locations) and age group (young and old), and one within-subject variable: valence (positive, neutral, negative).

I am looking at an Stevens(one between, two within) in Notes on the use of R for psychology experiments and questionnaires (P34 in this article).

In Stevens' example, he first create a matrix and put the data in a multivariate format using cbind.data.frame() function.

Ela.mat <- matrix (c(19,.....28), nrow=16, byrow=T)
Ela.mul <- cbind.data.frame(subj=1:16, gp=factor(rep(1:2,rep(8,2))),
Ela.mat)

dimnames(Ela.mul)[[2]] <-
c("subj","gp","d11","d12","d13","d21","d22","d23")

My data includes 447 data points:

5,4,5,
2,1,4,
4,7,8,
0,4,5,
3,1,7,
1,4,2,
3,2,5,
2,5,6,
4,2,6,

......
The three columns are positive, neutral and negative. First 31 rows are Young* location 1, next 39 Old* location1, next 43 Young* location2, and the final 36 Old *location2.

I have 2 grouping variables and thus 4 uneven groups. Any suggestion for how I can group them in cbind.data.frame()?

Or is there any suggestion for how to analyze in this 3 (valence: positive, negative, neutral) X 2 (age: young vs. old) X 2 (location: a vs. b) mixed Analysis of Variance (ANOVA)?

Thank you very much. Any and all help will be immensely appreciated.

--
View this message in context: http://r.789695.n4.nabble.com/Mixed-design-ANOVA-2-between-subject-factors-and-1-within-subject-factor-tp3508819p3508819.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help_at_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.
Received on Mon 09 May 2011 - 12:35:47 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 09 May 2011 - 12:40:06 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive