[R-sig-ME] Mixed model nesting query

Etn bot etnbot1 at gmail.com
Wed Sep 16 15:50:07 CEST 2015


Hi all,

I have a quick question relating to the specification of a linear mixed
model (I'm relatively new to R and I would be very grateful for any
advice). I have fit a linear mixed model but it does not answer my desired
question, thus I think I have set-up my model incorrectly....

My study looks at allergy levels of skin patches from patients and readings
(repeated 5 times) are measured over 4 time points

I need to determine if the allergy level for skin patch changes over time
(e.g. if allergy level from skin patch 1 for patient 1 at time 0 is
different from allergy level for skin patch 1 for patient 1 at time 1 etc.)
I do not want to see the difference between skin patch 1 and skin patch
2....

I'm really unsure how to set up this type of nesting... as

model<-lmer(allergy_level ~ time+skin +(time|reading/patient))

does not give me the desired result.


There are 7 skin patches per patient. (10 patients in total)
5 readings are taken at each of the 4 time points

my data is in the format

Patient ID        Skin patch ID     Reading       TimePoint     Allergy
Level
1                               1
1                        0                1.2
1                               1
2                        0                 1.4
1                               1
3                        0                 1.1
:                                                     :



Many thanks for reading my post. Any advice is greatly appreciated.

Kind regards

Etn

	[[alternative HTML version deleted]]



More information about the R-sig-mixed-models mailing list