There are four variables in my dataset. It is in the long format and looks something like this (simplified).
ID = participant ID,
Object = various objects such as a cup, a plate, a notebook,
Like= likability rating for each object, and
Use= rating for how likely the participant is to use the object.
My hypothesis is that Like will predict Use.
My question is: Is this the right way to model a multilevel model in R for the above mentioned data set:
intercept<-gls(Use~1, data=mydata, method="ML")
randomIntercept<-lme(Use~1, data=mydata, random=~1|ID, method="ML")
randomInterceptLike<-update(randomIntercept, .~. + Like)
randomInterceptLikerandomSlope<-update(randomInterceptLike, random=~ID|Object)