フィルターのクリア

Extending repeated measures ANOVA to linear mixed effects model

7 ビュー (過去 30 日間)
bsriv
bsriv 2022 年 9 月 19 日
コメント済み: Jeff Miller 2022 年 9 月 21 日
Hi, I currently have data on a group of participants undergoing an identical experiment in which they submit a rating after a given instruction/cue set at two separate timepoints that I have analyzed using repeated measures ANOVA:
t=table(inst1_cue1_pre_rating_mean_stack,inst1_cue1_post_rating_mean_stack,inst2_cue1_pre_rating_mean_stack,inst2_cue1_post_rating_mean_stack,inst1_cue2_pre_rating_mean_stack,inst1_cue2_post_rating_mean_stack,inst2_cue2_pre_rating_mean_stack,inst2_cue2_post_rating_mean_stack,'VariableNames',{'inst1_cue1_pre','inst1_cue1_post','inst2_cue1_pre','inst2_cue1_post','inst1_cue2_pre','inst1_cue2_post','inst2_cue2_pre','inst2_cue2_post'}); with instruction ("inst1/inst2"), cue ("cue1/cue2") and time (pre/post) as categorical variables
WithinStructure=table([1 1 2 2 1 1 2 2]',[1 1 1 1 2 2 2 2]',[1 2 1 2 1 2 1 2]','VariableNames',{'instruction','picture','time'});
WithinStructure.instruction = categorical(WithinStructure.instruction);
WithinStructure.picture = categorical(WithinStructure.picture);
rm=fitrm(t,'look_alc_pre-negative_food_post~1','WithinDesign',WithinStructure);
ranovatbl=ranova(rm,'WithinModel','instruction*picture*time')
My question is, I would like to extend this to a linear mixed effects model, where instead of pre and post I would like to have a continuous variable interval days between session ("intervals")
So I have gotten as far as setting up the table for the lme:
pre_table=table(inst1_cue1_pre_rating_mean_stack,inst2_cue1_pre_rating_mean_stack,inst1_cue2_pre_rating_mean_stack,inst2_cue2_pre_rating_mean_stack,intervals_baseline)
, where intervals_baseline is a column of zeros the size of the participant group
post_table=table(inst1_cue1_post_rating_mean_stack,inst2_cue1_post_rating_mean_stack,inst1_cue2_post_rating_mean_stack,inst2_cue2_post_rating_mean_stack,intervals_post)
where intervals_post is the number of days for each participant between tests
tbl=[tbl_pre;tbl_post]
My question is how to extract (or code) the categorical variables for the linear mixed effects model, which I think should be rating~instruction+cue+intervals (and I would like the interaction terms instruction*intervals and cue*intervals) but I'm a little lost on how to set this up. Do I code the fixed effects as in the anova? And what about the dependent variable?
Thank you!
  3 件のコメント
bsriv
bsriv 2022 年 9 月 20 日
Hi- thanks for the response
I have 22 particpants and here is a histogram (x axis = #days between sessions, y axis # of participants)
Jeff Miller
Jeff Miller 2022 年 9 月 21 日
That's not a lot of participants, and they are mostly squished together in that 90-100 range, so I doubt you have much power to detect an influence of the interval length. If you want to try, I'd suggest using a median split on interval to divide the participants into two groups (short vs long interval) and then treating that division as a between-Ss factor in the ANOVA. If it is practical in a future study looking harder at interval, maybe randomly assign participants into more distinct short- and long-interval groups (e.g., 80-95 and 110-125).

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeAnalysis of Variance and Covariance についてさらに検索

製品


リリース

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by