Generation

generate functionTue, 18 Apr 2023

dependent variable: 'direction' has three levels: morning, noon, night. There is no reference level for 'direction' > table(indvar_FODs_new$direction) morning noon night 1683 1432 206 fixed factor/independent variable: 'Cond' has four levels: Ay, Bi, Ci, Di. There is no reference level for 'Cond' > table(indvar_FODs$Cond) Ay Bi Ci Di 880 880 880 880 random factor: 'colours' has two levels: blue and pink. > table(indvar_FODs_new$colours) blue pink 2720 800 I am using Rstudio. I want to statistically test if 'Cond' and 'colours', and the interaction effect between 'Cond' and 'colours' can affect the 'direction' value frequencies. Which statistical test and code would be ideal to conduct this analysis? data is categorical data

indvar_FODs_new Cond colours direction 1 Ay blue morning 2 Ay pink morning 3 Ay pink morning 4 Ay pink morning 5 Ay pink morning 6 Ay pink morning 7 Ay pink morning 8 Ay blue morning 9 Ay blue morning 10 Ay pink morning 11 Ay pink morning 12 Ay blue morning 13 Ay blue morning 14 Ay blue morning 15 Ay blue morning 16 Ay blue morning 17 Ay blue morning 18 Ay blue morning 19 Ay pink morning 20 Ay blue morning 21 Ay blue morning 22 Ay blue morning 23 Ay blue morning 24 Ay blue morning 25 Ay blue morning 26 Ay blue morning 27 Ay blue morning 28 Ay blue morning 29 Ay blue morning 30

Questions about programming?Chat with your personal AI assistant