I have drawing data from 10 subjects drawing 8 shapes (and many repetitions of every shape). I fitted a model to this data Matlab, separately for each subject and each shapes, such that I have 2 model- parameters and an r^2 measure of the goodness of fit, in an 8x10 matrix (8 shapes, 10 subjects).
For each of these 3 variables I would like to know:
Does the parameter differ between shapes?
Do subjects differ in the parameter?
I think I need a linear mixed-model, where shapes are fixed and subjects are random, but I’m not sure (shapes are categorical, but this can still be modeled by linear models, right?).
I tried the following:
gamma.model = lmer(gamma ~ Shape + (1|Subject), data = gammatable, REML = FALSE)
summary(gamma.model) shows me a p-value for shape1 vs. every other shape, but not the relation between shape2 and shape 8 (for instance).
There is also no mentioning at all of random effects...?
Can someone please help me understand -
If indeed I need a mixed-model (or if not – what do I need?)
How to define it correctly in lme4 (or other)
How to perform multiple comparisons and get p-values for fixed, as well as for random effects?
Thanks a lot!