I have 2 factors
B (5×3) and one covariate
X in a within subject design. Here's how I specify my overall model:
lme.out = lme(y~ A*B*X, random=~1|Subject, data=mydata)
My interpretation is that I am looking at a graph
y~x, where the slope changes due to the covariate, and the line shifts up or down based on the different levels of
B (changes in intercepts).
What I want to find out is: if I were to fix factor
A (take any of the levels), then looking at the lines (
y~x), what is the effect of
B? Does the levels of
B shift the line up or down (intercepts) or does it alter the slope of the line (
Should I be running some sort of contrasts analysis? But I am not sure how contrasts work between factors and covariates.
One way I could think of is to take the subsets of data corresponding to different levels of A and create models such as:
lme(y~ B+X, random=~1|Subject, data=mydata[which(mydata$A = A1,]). This way I could compare the resulting intercepts and slopes across these models.
Can anyone tell me if what I am doing make sense? Suggestions of any kind would be greatly appreciated!