|
9 | 9 | }, |
10 | 10 | { |
11 | 11 | "cell_type": "code", |
12 | | - "execution_count": 35, |
| 12 | + "execution_count": null, |
13 | 13 | "metadata": {}, |
14 | 14 | "outputs": [], |
15 | 15 | "source": [ |
|
34 | 34 | }, |
35 | 35 | { |
36 | 36 | "cell_type": "code", |
37 | | - "execution_count": 36, |
| 37 | + "execution_count": null, |
38 | 38 | "metadata": { |
39 | 39 | "scrolled": true |
40 | 40 | }, |
|
65 | 65 | }, |
66 | 66 | { |
67 | 67 | "cell_type": "code", |
68 | | - "execution_count": 37, |
| 68 | + "execution_count": null, |
69 | 69 | "metadata": {}, |
70 | | - "outputs": [ |
71 | | - { |
72 | | - "name": "stdout", |
73 | | - "output_type": "stream", |
74 | | - "text": [ |
75 | | - "\n", |
76 | | - "Data will be saved in this directory:\n", |
77 | | - "\t/home/remi/github/CPP_BIDS/notebooks/new_experiment/source/sub-001/ses-001/beh\n", |
78 | | - "\n", |
79 | | - "Data will be saved in this file:\n", |
80 | | - "\tsub-001_ses-001_task-testTask_run-001_events_date-202011171630.tsv\n", |
81 | | - "onset\tduration\ttrial_type\n" |
82 | | - ] |
83 | | - } |
84 | | - ], |
| 70 | + "outputs": [], |
85 | 71 | "source": [ |
86 | 72 | "cfg = createFilename(cfg);\n", |
87 | 73 | "logFile = saveEventsFile('init', cfg);\n", |
|
99 | 85 | }, |
100 | 86 | { |
101 | 87 | "cell_type": "code", |
102 | | - "execution_count": 38, |
| 88 | + "execution_count": null, |
103 | 89 | "metadata": {}, |
104 | | - "outputs": [ |
105 | | - { |
106 | | - "name": "stdout", |
107 | | - "output_type": "stream", |
108 | | - "text": [ |
109 | | - "2.000000\t0.250000\ttarget\t\r\n", |
110 | | - "5.000000\t0.360000\tno_target\t\r\n" |
111 | | - ] |
112 | | - } |
113 | | - ], |
| 90 | + "outputs": [], |
114 | 91 | "source": [ |
115 | 92 | "logFile(1, 1).onset = 2;\n", |
116 | 93 | "logFile(1, 1).trial_type = 'target';\n", |
|
125 | 102 | }, |
126 | 103 | { |
127 | 104 | "cell_type": "code", |
128 | | - "execution_count": 39, |
| 105 | + "execution_count": null, |
129 | 106 | "metadata": {}, |
130 | | - "outputs": [ |
131 | | - { |
132 | | - "name": "stdout", |
133 | | - "output_type": "stream", |
134 | | - "text": [ |
135 | | - "\r\n", |
136 | | - "Data were saved in this file:\r\n", |
137 | | - "\r\n", |
138 | | - "/home/remi/github/CPP_BIDS/notebooks/new_experiment/source/sub-001/ses-001/beh/sub-001_ses-001_task-testTask_run-001_events_date-202011171630.tsv\r\n", |
139 | | - "\r\n" |
140 | | - ] |
141 | | - } |
142 | | - ], |
| 107 | + "outputs": [], |
143 | 108 | "source": [ |
144 | 109 | "% close the file\n", |
145 | 110 | "saveEventsFile('close', cfg, logFile);" |
|
154 | 119 | }, |
155 | 120 | { |
156 | 121 | "cell_type": "code", |
157 | | - "execution_count": 40, |
| 122 | + "execution_count": null, |
158 | 123 | "metadata": { |
159 | 124 | "scrolled": true |
160 | 125 | }, |
161 | | - "outputs": [ |
162 | | - { |
163 | | - "name": "stdout", |
164 | | - "output_type": "stream", |
165 | | - "text": [ |
166 | | - "\u001b[01;34mnew_experiment\u001b[00m\r\n", |
167 | | - "└── \u001b[01;34msource\u001b[00m\r\n", |
168 | | - " └── \u001b[01;34msub-001\u001b[00m\r\n", |
169 | | - " └── \u001b[01;34mses-001\u001b[00m\r\n", |
170 | | - " └── \u001b[01;34mbeh\u001b[00m\r\n", |
171 | | - " ├── sub-001_ses-001_task-testTask_run-001_events_date-202011171630.json\r\n", |
172 | | - " └── sub-001_ses-001_task-testTask_run-001_events_date-202011171630.tsv\r\n", |
173 | | - "\r\n", |
174 | | - "4 directories, 2 files\r\n", |
175 | | - "\n" |
176 | | - ] |
177 | | - } |
178 | | - ], |
| 126 | + "outputs": [], |
179 | 127 | "source": [ |
180 | 128 | "!tree new_experiment" |
181 | 129 | ] |
182 | 130 | }, |
183 | 131 | { |
184 | 132 | "cell_type": "code", |
185 | | - "execution_count": 41, |
| 133 | + "execution_count": null, |
186 | 134 | "metadata": {}, |
187 | | - "outputs": [ |
188 | | - { |
189 | | - "name": "stdout", |
190 | | - "output_type": "stream", |
191 | | - "text": [ |
192 | | - "onset\tduration\ttrial_type\r\n", |
193 | | - "2.000000\t0.250000\ttarget\t\r\n", |
194 | | - "5.000000\t0.360000\tno_target\t\r\n", |
195 | | - "\n" |
196 | | - ] |
197 | | - } |
198 | | - ], |
| 135 | + "outputs": [], |
199 | 136 | "source": [ |
200 | 137 | "!cat new_experiment/source/sub-001/ses-001/beh/sub-001_ses-001_task-testTask_run-001_events_date-*.tsv" |
201 | 138 | ] |
202 | 139 | }, |
203 | 140 | { |
204 | 141 | "cell_type": "code", |
205 | | - "execution_count": 34, |
| 142 | + "execution_count": null, |
206 | 143 | "metadata": {}, |
207 | | - "outputs": [ |
208 | | - { |
209 | | - "name": "stdout", |
210 | | - "output_type": "stream", |
211 | | - "text": [ |
212 | | - "{\r\n", |
213 | | - " \"onset\": {\r\n", |
214 | | - " \"Description\": \"time elapsed since experiment start\",\r\n", |
215 | | - " \"Units\": \"s\"\r\n", |
216 | | - " },\r\n", |
217 | | - " \"trial_type\": {\r\n", |
218 | | - " \"Description\": \"types of trial\",\r\n", |
219 | | - " \"Levels\": \"\"\r\n", |
220 | | - " },\r\n", |
221 | | - " \"duration\": {\r\n", |
222 | | - " \"Description\": \"duration of the event or the block\",\r\n", |
223 | | - " \"Units\": \"s\"\r\n", |
224 | | - " }\r\n", |
225 | | - "}\n" |
226 | | - ] |
227 | | - } |
228 | | - ], |
| 144 | + "outputs": [], |
229 | 145 | "source": [ |
230 | 146 | "!cat new_experiment/source/sub-001/ses-001/beh/sub-001_ses-001_task-testTask_run-001_events_date-*.json" |
231 | 147 | ] |
|
0 commit comments