I have my data like this. 100 patients are asked 3 sets of questions every year (for 5 years) and they were given a score for each sets of question. So I have data like this
id year s1 s2 s3
1 1 60 30 50
1 2 65 30 45
1 3 40 25 50
1 4 34 20 40
1 5 32 23 45
2 1 32 43 32
...
I want to fit a mixed model in R with lme4. I transformed the data into this long format:
id year score question
1 1 60 1
1 1 30 2
1 1 50 3
1 2 65 1
1 2 30 2
1 2 45 3
...
So my question is how should I fit this model?
I am new to mixed model; I am thinking:
score~1+year+(1+year|id)+(1+year|question)
But not sure if this is right.
I appreciate your suggestions!