I have a complex experimental design with two within-subject factors and one between-subject factor, where my outcome variable is measured on a binary response.
Country (Between-subject, 2 levels: A and B)
Experiment (Within-subject, 5 levels: 1,2,3,4)
Trial (Within-subject, 3 levels: 1,2,3)
DV/outcome measure is a binary response (success or failure).
This means all the subjects go through all possible 15 conditions (5 Experiments x 3 Trials).
I want to know:
If there is a Country group difference in Trials across different Experiments, in other words, if there is a three-way interaction.
If there is an interaction, and I want to explore pairwise comparisons (e.g., is Country A more likely to succeed in Trial 1 in Experiment 1 than Country B?). I do not have specific hypotheses about which specific pairs would be different, however.
This would have been easier to test using three-way mixed-factorial ANOVA if my DV is a continuous variable, but my understanding is I won't be able to test in parametric procedures including ANOVAs. Would Generalized Linear Mixed Modeling (GLMM) with a binomial distribution option be the appropriate procedure to pursue and if so, how do I write this out in lme4 function in R?
My understanding is that Subject would be a random effect, and Country would be a fixed effect, but not sure about Experiment and Trial variables.
I am also a bit confused with which variable is crossed vs. nested. Do I have any nesting variables?
I am in Psychology and very new to multilevel modeling and mixed-effects modeling, so I would greatly appreciate your help and the simplest way to test it.