Using Jamovi I can carry out a two-way ANOVA (Ratio as dep var; Optim & Sex as indep vars) on the following small dataset:
dput(swimming)
structure(list(Optim = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L,
1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L), .Label = c("Optimists",
"Pessimists"), class = "factor"), Sex = structure(c(2L, 2L, 2L,
2L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L), .Label = c("Female",
"Male"), class = "factor"), Event = structure(c(1L, 1L, 1L, 1L,
1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L), .Label = "Free", class = "factor"),
Ratio = c(0.986, 1.108, 0.952, 0.998, 1.108, 0.985, 1.001,
0.924, 0.968, 0.983, 0.947, 0.932, 1.078, 0.997, 0.983, 1.105,
1.116)), class = "data.frame", row.names = c(NA, -17L))
When I try to carry out the same analysis using jmv::ANOVA in R:
Code: Select all
swimming <- read.table('data/swimming_data2.csv', sep = ',', header=TRUE)
ANOVA(Ratio ~ Optim * Sex, data = swimming)
I get the following error:
Code: Select all
Error in .subset2(x, i, exact = exact) : invalid subscript type 'list'
Best,
i