-
Notifications
You must be signed in to change notification settings - Fork 0
/
rsa_lmer_model_list.R
190 lines (171 loc) · 14 KB
/
rsa_lmer_model_list.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
library(modelr)
models <- list()
models[['catFR1']] <- list()
models[['FR1']] <- list()
models[['RepFR1']] <- list()
models[['catFR1']][['encoding']] <- formulas(
~scale(corr_z),
m1 = ~(same_category * abs_serialpos_dist_center) +
(same_category * abs_serialpos_dist_center | subject_encoding) +
(same_category * abs_serialpos_dist_center | subject_encoding:session_encoding_encoding) +
(same_category * abs_serialpos_dist_center | subject_encoding:session_encoding:list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding2) +
(same_category * abs_serialpos_dist_center | list_encoding) +
(dummy(same_category) | serialpos_encoding) +
(dummy(same_category) | serialpos_encoding2) +
(same_category | serialpos_encoding:serialpos_encoding2),
m1_final = ~(same_category * abs_serialpos_dist_scale) +
(dummy(same_category) * abs_serialpos_dist_scale || subject_encoding) +
(abs_serialpos_dist_scale + dummy(same_category):abs_serialpos_dist_scale || subject_encoding:session_encoding) +
(abs_serialpos_dist_scale || subject_encoding:session_encoding:list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
# (1 | subject:session:list:serialpos_encoding2) +
(1 | list_encoding) +
(dummy(same_category) || serialpos_encoding) +
(0 + dummy(same_category) || serialpos_encoding2) +
(dummy(same_category) || serialpos_encoding:serialpos_encoding2),
)
models[['catFR1']][['encoding_isi']] <- formulas(
~scale(corr_z),
m1 = ~((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category) +
((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category | subject_encoding) +
((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category | subject_encoding:session_encoding) +
((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category | subject_encoding:session_encoding:list_encoding) +
((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category | list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:prev_serialpos_encoding_isi) +
((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category | serialpos_encoding) +
((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category | prev_serialpos_encoding_isi) +
((item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category | serialpos_encoding:prev_serialpos_encoding_isi),
m1_final = ~(item_first + item_recalled) * item_before_isi_recalled * same_category + recall_neighbor + recall_neighbor:same_category +
(dummy(item_first) * dummy(item_before_isi_recalled) + dummy(item_recalled):dummy(item_before_isi_recalled) + dummy(item_recalled):dummy(same_category) || subject_encoding) +
(dummy(item_first) + dummy(item_recalled) || subject_encoding:session_encoding) +
(dummy(item_recalled) + dummy(item_recalled):dummy(item_before_isi_recalled) + (dummy(item_before_isi_recalled) * dummy(same_category)) || subject_encoding:session_encoding:list_encoding) +
(dummy(item_recalled) * dummy(item_before_isi_recalled) || list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:prev_serialpos_encoding_isi) +
(dummy(item_recalled) * dummy(same_category) + dummy(item_before_isi_recalled) + dummy(item_recalled):dummy(item_before_isi_recalled):dummy(same_category) + dummy(same_category):dummy(recall_neighbor) || serialpos_encoding) +
(dummy(item_before_isi_recalled) + dummy(item_first):dummy(same_category) + dummy(same_category):dummy(recall_neighbor) || prev_serialpos_encoding_isi) +
(dummy(same_category) | serialpos_encoding:prev_serialpos_encoding_isi),
)
models[['catFR1']][['encoding_end']] <- formulas(
~scale(corr_z),
m1 = ~((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category) +
((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category | subject_encoding) +
((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category | subject_encoding:session_encoding) +
((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category | subject_encoding:session_encoding:list_encoding) +
((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category | list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding_end) +
((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category | serialpos_encoding) +
((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category | serialpos_encoding_end) +
((item_first + item_recalled) * current_item_recalled * same_category + recall_neighbor + recall_neighbor:same_category | serialpos_encoding:serialpos_encoding_end),
m1_final = ~((item_first + item_recalled) * current_item_recalled * same_category) + recall_neighbor + recall_neighbor:same_category +
((dummy(item_first) + dummy(current_item_recalled) + dummy(same_category))^2 - dummy(item_first):dummy(current_item_recalled) || subject_encoding) +
(dummy(item_first) + dummy(item_recalled) || subject_encoding:session_encoding) +
(dummy(item_recalled) + dummy(same_category) | subject_encoding:session_encoding:list_encoding) +
(dummy(item_recalled) + dummy(item_first):dummy(current_item_recalled) || list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding_end) +
(dummy(item_recalled) * dummy(current_item_recalled) || serialpos_encoding) +
(dummy(same_category) + dummy(recall_neighbor) || serialpos_encoding_end) +
(dummy(item_first) + dummy(same_category):dummy(recall_neighbor) || serialpos_encoding:serialpos_encoding_end),
)
models[['catFR1']][['distractor']] <- formulas(
~scale(corr_z),
m1 = ~(item_first + item_recalled) * serialpos_scale +
((item_first + item_recalled) * serialpos_scale | subject_encoding) +
((item_first + item_recalled) * serialpos_scale | subject_encoding:session_encoding) +
((item_first + item_recalled) * serialpos_scale | subject_encoding:session_encoding:list_encoding) +
((item_first + item_recalled) * serialpos_scale | list_encoding) +
(item_first + item_recalled | serialpos_encoding) +
(item_first + item_recalled | serialpos_encoding:subject_encoding:session_encoding),
m1_final = ~(item_first + item_recalled) * serialpos_scale +
(dummy(item_first) + (dummy(item_recalled) * serialpos_scale) || subject_encoding) +
(serialpos_scale + dummy(item_recalled) || subject_encoding:session_encoding) +
(1 | subject_encoding:session_encoding:list_encoding) +
(serialpos_scale | list_encoding) +
(1 | serialpos_encoding) +
(1 | serialpos_encoding:subject_encoding:session_encoding),
)
models[['FR1']][['encoding_isi']] <- formulas(
~scale(corr_z),
m1 = ~((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor) +
((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor | subject_encoding) +
((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor | subject_encoding:session_encoding) +
((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor | subject_encoding:session_encoding:list_encoding) +
((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor | list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:prev_serialpos_encoding_isi) +
((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor | serialpos_encoding) +
((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor | prev_serialpos_encoding_isi) +
((item_first + item_recalled) * item_before_isi_recalled + recall_neighbor | serialpos_encoding:prev_serialpos_encoding_isi),
m1_final = ~((item_first + item_recalled) * item_before_isi_recalled) + recall_neighbor +
(dummy(item_recalled) + dummy(item_first) + dummy(item_before_isi_recalled) || subject_encoding) +
(dummy(item_first) + dummy(item_recalled) || subject_encoding:session_encoding) +
(dummy(item_first) || subject_encoding:session_encoding:list_encoding) +
(dummy(recall_neighbor) || list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:prev_serialpos_encoding_isi) +
((dummy(item_recalled) * dummy(item_before_isi_recalled)) + dummy(recall_neighbor) || serialpos_encoding) +
(dummy(item_first) || prev_serialpos_encoding_isi) +
(dummy(item_recalled) | serialpos_encoding:prev_serialpos_encoding_isi),
)
models[['FR1']][['encoding_end']] <- formulas(
~scale(corr_z),
m1 = ~((item_first + item_recalled) * current_item_recalled + recall_neighbor) +
((item_first + item_recalled) * current_item_recalled + recall_neighbor | subject_encoding) +
((item_first + item_recalled) * current_item_recalled + recall_neighbor | subject_encoding:session_encoding) +
((item_first + item_recalled) * current_item_recalled + recall_neighbor | subject_encoding:session_encoding:list_encoding) +
((item_first + item_recalled) * current_item_recalled + recall_neighbor | list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding_end) +
((item_first + item_recalled) * current_item_recalled + recall_neighbor | serialpos_encoding) +
((item_first + item_recalled) * current_item_recalled + recall_neighbor | serialpos_encoding_end) +
((item_first + item_recalled) * current_item_recalled + recall_neighbor | serialpos_encoding:serialpos_encoding_end),
m1_final = ~((item_first + item_recalled) * current_item_recalled + recall_neighbor) +
((dummy(item_recalled) * dummy(current_item_recalled)) + dummy(item_first) || subject_encoding) +
(dummy(item_first) + dummy(item_recalled):dummy(current_item_recalled) + dummy(current_item_recalled) || subject_encoding:session_encoding) +
(dummy(recall_neighbor) || subject_encoding:session_encoding:list_encoding) +
(dummy(item_first):dummy(current_item_recalled) + dummy(item_recalled) + dummy(current_item_recalled) + dummy(recall_neighbor) || list_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding) +
(1 | subject_encoding:session_encoding:list_encoding:serialpos_encoding_end) +
(dummy(item_first) + (dummy(item_recalled) * dummy(current_item_recalled)) || serialpos_encoding) +
((dummy(item_recalled) * dummy(current_item_recalled)) || serialpos_encoding_end) +
(dummy(item_first) + dummy(item_recalled) + dummy(recall_neighbor) || serialpos_encoding:serialpos_encoding_end)
)
models[['FR1']][['distractor']] <- formulas(
~scale(corr_z),
m1 = ~(item_first + item_recalled) * serialpos_scale +
((item_first + item_recalled) * serialpos_scale | subject_encoding) +
((item_first + item_recalled) * serialpos_scale | subject_encoding:session_encoding) +
((item_first + item_recalled) * serialpos_scale | subject_encoding:session_encoding:list_encoding) +
((item_first + item_recalled) * serialpos_scale | list_encoding) +
(item_first + item_recalled | serialpos_encoding) +
(item_first + item_recalled | serialpos_encoding:subject_encoding:session_encoding),
m1_final = ~(item_first + item_recalled) * serialpos_scale +
(dummy(item_recalled) * serialpos_scale | subject_encoding) +
(dummy(item_first) + dummy(item_recalled) + serialpos_scale | subject_encoding:session_encoding) +
(serialpos_scale | subject_encoding:session_encoding:list_encoding) +
(dummy(item_first):serialpos_scale + serialpos_scale + dummy(item_recalled):serialpos_scale || list_encoding) +
(dummy(item_first) | serialpos_encoding) +
(1 | serialpos_encoding:subject_encoding:session_encoding)
)
models[['RepFR1']][['distractor']] <- formulas(
~scale(corr_z),
m1 = ~(item_first + item_recalled) * serialpos_scale +
((dummy(item_first) + dummy(item_recalled)) * serialpos_scale | subject_encoding) +
((dummy(item_first) + dummy(item_recalled)) * serialpos_scale | subject_encoding:session_encoding) +
((dummy(item_first) + dummy(item_recalled)) * serialpos_scale | subject_encoding:session_encoding:list_encoding) +
((dummy(item_first) + dummy(item_recalled)) * serialpos_scale | list_encoding) +
((dummy(item_first) + dummy(item_recalled)) | serialpos_encoding) +
((dummy(item_first) + dummy(item_recalled)) | serialpos_encoding:subject_encoding:session_encoding),
m1_final = ~(item_first + item_recalled) * serialpos_scale +
(serialpos_scale + dummy(item_first):serialpos_scale || subject_encoding) +
(dummy(item_recalled) + serialpos_scale || subject_encoding:session_encoding) +
(dummy(item_recalled) * serialpos_scale | subject_encoding:session_encoding:list_encoding) +
(serialpos_scale + dummy(item_recalled):serialpos_scale || list_encoding) +
(dummy(item_first) | serialpos_encoding) +
(1 | serialpos_encoding:subject_encoding:session_encoding)
)