Skip to content

Commit b2246fc

Browse files
committed
add dummy term URL
1 parent 94aa529 commit b2246fc

File tree

6 files changed

+17
-18
lines changed

6 files changed

+17
-18
lines changed

src/createDataDictionary.m

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,7 @@ function createDataDictionary(cfg, logFile)
4848
startTime = logFile(1).StartTime;
4949
end
5050

51-
jsonContent = struct( ...
52-
'SamplingFrequency', samplingFrequency, ...
51+
jsonContent = struct('SamplingFrequency', samplingFrequency, ...
5352
'StartTime', startTime, ...
5453
'Columns', []);
5554
end

src/saveEventsFile.m

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,8 @@
185185
logFile(1).columns = struct('onset', struct('Description', ...
186186
'time elapsed since experiment start', ...
187187
'Units', 's'), ...
188-
'trial_type', struct('Description', 'types of trial'), ...
188+
'trial_type', struct('Description', 'types of trial', ...
189+
'Levels', struct()), ...
189190
'duration', struct('Description', ...
190191
'duration of the event or the block', ...
191192
'Units', 's') ...

src/utils/initializeExtraColumns.m

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
fieldsToSet.bids.LongName = '';
2525
fieldsToSet.bids.Description = '';
2626
fieldsToSet.bids.Levels = struct();
27-
fieldsToSet.bids.TermURL = '';
27+
fieldsToSet.bids.TermURL = 'www.TODO.later';
2828
fieldsToSet.bids.Units = '';
2929

3030
% convert the cell of column name into a structure
@@ -35,8 +35,7 @@
3535

3636
for iExtraColumn = 1:nbExtraColumns
3737
extraColumnName = logFile(1).extraColumns{iExtraColumn};
38-
tmp.(extraColumnName) = struct( ...
39-
'length', 1);
38+
tmp.(extraColumnName) = struct('length', 1);
4039
tmp.(extraColumnName) = setDefaultFields(tmp.(extraColumnName), fieldsToSet);
4140
end
4241

tests/testData/eventsDataDictionary.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,28 +15,28 @@
1515
"LongName": "",
1616
"Description": "",
1717
"Levels": {},
18-
"TermURL": "",
18+
"TermURL": "www.TODO.later",
1919
"Units": ""
2020
},
2121
"LHL24_01": {
2222
"LongName": "",
2323
"Description": "",
2424
"Levels": {},
25-
"TermURL": "",
25+
"TermURL": "www.TODO.later",
2626
"Units": ""
2727
},
2828
"LHL24_02": {
2929
"LongName": "",
3030
"Description": "",
3131
"Levels": {},
32-
"TermURL": "",
32+
"TermURL": "www.TODO.later",
3333
"Units": ""
3434
},
3535
"LHL24_03": {
3636
"LongName": "",
3737
"Description": "",
3838
"Levels": {},
39-
"TermURL": "",
39+
"TermURL": "www.TODO.later",
4040
"Units": ""
4141
}
4242
}

tests/testData/stimDataDictionary.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,35 +12,35 @@
1212
"Description": "",
1313
"Levels": {},
1414
"LongName": "",
15-
"TermURL": "",
15+
"TermURL": "www.TODO.later",
1616
"Units": ""
1717
},
1818
"LHL24_01": {
1919
"Description": "",
2020
"Levels": {},
2121
"LongName": "",
22-
"TermURL": "",
22+
"TermURL": "www.TODO.later",
2323
"Units": ""
2424
},
2525
"LHL24_02": {
2626
"Description": "",
2727
"Levels": {},
2828
"LongName": "",
29-
"TermURL": "",
29+
"TermURL": "www.TODO.later",
3030
"Units": ""
3131
},
3232
"LHL24_03": {
3333
"Description": "",
3434
"Levels": {},
3535
"LongName": "",
36-
"TermURL": "",
36+
"TermURL": "www.TODO.later",
3737
"Units": ""
3838
},
3939
"is_Fixation": {
4040
"Description": "",
4141
"Levels": {},
4242
"LongName": "",
43-
"TermURL": "",
43+
"TermURL": "www.TODO.later",
4444
"Units": ""
4545
}
4646
}

tests/test_saveEventsFileInit.m

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function test_saveEventsFileInitExtraColumns()
5656
expectedStrcut(1).extraColumns.Speed.bids.LongName = '';
5757
expectedStrcut(1).extraColumns.Speed.bids.Description = '';
5858
expectedStrcut(1).extraColumns.Speed.bids.Levels = struct();
59-
expectedStrcut(1).extraColumns.Speed.bids.TermURL = '';
59+
expectedStrcut(1).extraColumns.Speed.bids.TermURL = 'www.TODO.later';
6060
expectedStrcut(1).extraColumns.Speed.bids.Units = '';
6161

6262
%% test
@@ -83,13 +83,13 @@ function test_saveEventsFileInitExtraColumnsArray()
8383
expectedStrcut(1).extraColumns.Speed.bids.LongName = '';
8484
expectedStrcut(1).extraColumns.Speed.bids.Description = '';
8585
expectedStrcut(1).extraColumns.Speed.bids.Levels = struct();
86-
expectedStrcut(1).extraColumns.Speed.bids.TermURL = '';
86+
expectedStrcut(1).extraColumns.Speed.bids.TermURL = 'www.TODO.later';
8787
expectedStrcut(1).extraColumns.Speed.bids.Units = '';
8888
expectedStrcut(1).extraColumns.LHL24.length = 3;
8989
expectedStrcut(1).extraColumns.LHL24.bids.LongName = '';
9090
expectedStrcut(1).extraColumns.LHL24.bids.Description = '';
9191
expectedStrcut(1).extraColumns.LHL24.bids.Levels = struct();
92-
expectedStrcut(1).extraColumns.LHL24.bids.TermURL = '';
92+
expectedStrcut(1).extraColumns.LHL24.bids.TermURL = 'www.TODO.later';
9393
expectedStrcut(1).extraColumns.LHL24.bids.Units = '';
9494

9595
%% test

0 commit comments

Comments
 (0)