Commit 4cfc9716 authored by Tyler Collins's avatar Tyler Collins
Browse files

Added the updated bids init structure code

parent 964bc9ee
......@@ -16,26 +16,20 @@ init_bids_root_script
%manual edit of dataset_description.json and participants.tsv
init_bids_sub_script('.','',...
'TaskName', 'FaceFO', ...
'TaskDescription', 'Visual presentation of oval cropped face and house images both upright and inverted. rare left and right half oval checkerboards were presetned as targets.', ...
'TaskName', 'FaceHouseCheck', ...
'TaskDescription', 'Visual presentation of oval cropped face and house images both upright and inverted. Rare left or right half oval checkerboards were presetned as targets for keypress response.', ...
'InstitutionName', 'Brock University', ...
'InstitutionAddress', '500 Glenrifge Ave, St.Catharines, Ontario', ...
'SamplingFrequency', 512, ...
'EEGChannelCount', 128, ...
'EOGChannelCount', 7, ...
'EOGChannelCount', 0, ...
'EMGChannelCount', 0, ...
'EEGReference', 'common', ...
'MiscChannelCount', 0, ...
'TriggerChannelCount', 0, ...
'PowerLineFrequency', '', ...
'PowerLineFrequency', '60Hz', ...
'EEGPlacementScheme', 'Custom equidistant 128 channel BioSemi montage established in coordination with Judith Schedden McMaster Univertisy', ...
'Manufacturer', 'BioSemi', ...
'ManufacturerModelName', 'ActiveTwo', ...
'HardwareFilters', 'DC to Nyquist 512Hz', ...
'SoftwareFilters', 'None', ...
'RecordingType', 'continuous', ...
'EpochLength', 'Inf', ...
'RecordingDuration', 2045, ...
'DeviceSoftwareVersion', 'NI ActiView 532-Lores', ...
'CapManufacturer', 'ElectroCap International', ...
'CapManufacturersModelName', '10032', ...
'CapManufacturersModelName', '10032');
......@@ -20,11 +20,11 @@ for i=1:length(EEG.chanlocs);
end
if isfield(EEG,'marks');
if EEG.marks.chan_info(1).flags(i);
channels{i+1,3}='good';
channels{i+1,3}='TRUE';
else
channels{i+1,3}='bad';
channels{i+1,3}='FALSE';
end
else
channels{i+1,3}='good';
channels{i+1,3}='TRUE';
end
end
......@@ -40,34 +40,51 @@ if isfield(opts,'DeviceSerialNumber');
end
sidecar_eeg.SamplingFrequency=EEG.srate;
sidecar_eeg.EEGChannelCount=EEG.nbchan;
sidecar_eeg.EOGChannelCount='';
sidecar_eeg.EMGChannelCount='';
if isfield(opts,'EOGChannelCount');
sidecar_eeg.EOGChannelCount=opts.EOGChannelCount;
else
sidecar_eeg.EOGChannelCount=0;
end
if isfield(opts,'EMGChannelCount');
sidecar_eeg.EMGChannelCount=opts.EMGChannelCount;
else
sidecar_eeg.EMGChannelCount=0;
end
sidecar_eeg.EEGReference=EEG.ref;
sidecar_eeg.MiscChannelCount='';
sidecar_eeg.TriggerChannelCount='';
if isfield(opts,'MiscChannelCount');
sidecar_eeg.MiscChannelCount=opts.MiscChannelCount;
else
sidecar_eeg.MiscChannelCount=0;
end
if isfield(opts,'TriggerChannelCount');
sidecar_eeg.TriggerChannelCount=opts.TriggerChannelCount;
else
sidecar_eeg.TriggerChannelCount=0;
end
if isfield(opts,'PowerLineFrequency');
sidecar_eeg.PowerLineFrequency='';
sidecar_eeg.PowerLineFrequency=opts.PowerLineFrequency;
end
if isfield(opts,'EEGPlacementScheme');
sidecar_eeg.EEGPlacementScheme='';
sidecar_eeg.EEGPlacementScheme=opts.EEGPlacementScheme;
end
if isfield(opts,'Manufacturer');
sidecar_eeg.Manufacturer='';
sidecar_eeg.Manufacturer=opts.Manufacturer;
end
if isfield(opts,'ManufacturerModelName');
sidecar_eeg.ManufacturerModelName='';
sidecar_eeg.ManufacturerModelName=opts.ManufacturerModelName;
end
if isfield(opts,'CapManufacturer');
sidecar_eeg.CapManufacturer='';
sidecar_eeg.CapManufacturer=opts.CapManufacturer;
end
if isfield(opts,'CapModelName');
sidecar_eeg.CapModelName='';
sidecar_eeg.CapModelName=opts.CapModelName;
end
if isfield(opts,'HardwareFilters');
sidecar_eeg.HardwareFilters='';
sidecar_eeg.HardwareFilters=opts.HardwareFilters;
end
if isfield(opts,'SoftwareFilters');
sidecar_eeg.SoftwareFilters='';
sidecar_eeg.SoftwareFilters=opts.SoftwareFilters;
end
if EEG.trials==1;
......@@ -82,10 +99,10 @@ else
end
if isfield(opts,'DeviceSoftwareVersion');
sidecar_eeg.DeviceSoftwareVersion='';
sidecar_eeg.DeviceSoftwareVersion=opts.DeviceSoftwareVersion;
end
if isfield(opts,'SubjectArtefactDescription');
sidecar_eeg.SubjectArtefactDescription='';
sidecar_eeg.SubjectArtefactDescription=opts.SubjectArtefactDescription;
end
%to propose
if isfield(opts,'Category')
......
......@@ -37,4 +37,93 @@ eeg_init({'sourcedata/eeg/IC_trn_P03_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P03_O_4.bdf'}, ...
'sub-s03/eeg/sub-s03_task-faceFO_eeg.set');
diary 'sourcedata/eeg/sub-s04.log';
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
system('mkdir -p sub-s04/eeg');
eeg_init({'sourcedata/eeg/IC_trn_P04_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P04_F_2.bdf', ...
'sourcedata/eeg/IC_trn_P04_F_3.bdf', ...
'sourcedata/eeg/IC_trn_P04_F_4.bdf', ...
'sourcedata/eeg/IC_trn_P04_O_1.bdf', ...
'sourcedata/eeg/IC_trn_P04_O_2.bdf', ...
'sourcedata/eeg/IC_trn_P04_O_3.bdf', ...
'sourcedata/eeg/IC_trn_P04_O_4.bdf'}, ...
'sub-s04/eeg/sub-s04_task-faceFO_eeg.set');
diary 'sourcedata/eeg/sub-s05.log';
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
system('mkdir -p sub-s05/eeg');
eeg_init({'sourcedata/eeg/IC_trn_P05_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P05_F_2.bdf', ...
'sourcedata/eeg/IC_trn_P05_F_3.bdf', ...
'sourcedata/eeg/IC_trn_P05_F_4.bdf', ...
'sourcedata/eeg/IC_trn_P05_O_1.bdf', ...
'sourcedata/eeg/IC_trn_P05_O_2.bdf', ...
'sourcedata/eeg/IC_trn_P05_O_3.bdf', ...
'sourcedata/eeg/IC_trn_P05_O_4.bdf'}, ...
'sub-s05/eeg/sub-s05_task-faceFO_eeg.set');
diary 'sourcedata/eeg/sub-s06.log';
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
system('mkdir -p sub-s06/eeg');
eeg_init({'sourcedata/eeg/IC_trn_P06_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P06_F_2.bdf', ...
'sourcedata/eeg/IC_trn_P06_F_3.bdf', ...
'sourcedata/eeg/IC_trn_P06_F_4.bdf', ...
'sourcedata/eeg/IC_trn_P06_O_1.bdf', ...
'sourcedata/eeg/IC_trn_P06_O_2.bdf', ...
'sourcedata/eeg/IC_trn_P06_O_3.bdf', ...
'sourcedata/eeg/IC_trn_P06_O_4.bdf'}, ...
'sub-s06/eeg/sub-s06_task-faceFO_eeg.set');
diary 'sourcedata/eeg/sub-s07.log';
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
system('mkdir -p sub-s07/eeg');
eeg_init({'sourcedata/eeg/IC_trn_P07_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P07_F_2.bdf', ...
'sourcedata/eeg/IC_trn_P07_F_3.bdf', ...
'sourcedata/eeg/IC_trn_P07_F_4.bdf', ...
'sourcedata/eeg/IC_trn_P07_O_1.bdf', ...
'sourcedata/eeg/IC_trn_P07_O_2.bdf', ...
'sourcedata/eeg/IC_trn_P07_O_3.bdf', ...
'sourcedata/eeg/IC_trn_P07_O_4.bdf'}, ...
'sub-s07/eeg/sub-s07_task-faceFO_eeg.set');
diary 'sourcedata/eeg/sub-s08.log';
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
system('mkdir -p sub-s08/eeg');
eeg_init({'sourcedata/eeg/IC_trn_P08_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P08_F_2.bdf', ...
'sourcedata/eeg/IC_trn_P08_F_3.bdf', ...
'sourcedata/eeg/IC_trn_P08_F_4.bdf', ...
'sourcedata/eeg/IC_trn_P08_O_1.bdf', ...
'sourcedata/eeg/IC_trn_P08_O_2.bdf', ...
'sourcedata/eeg/IC_trn_P08_O_3.bdf', ...
'sourcedata/eeg/IC_trn_P08_O_4.bdf'}, ...
'sub-s08/eeg/sub-s08_task-faceFO_eeg.set');
diary 'sourcedata/eeg/sub-s09.log';
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
system('mkdir -p sub-s09/eeg');
eeg_init({'sourcedata/eeg/IC_trn_P09_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P09_F_2.bdf', ...
'sourcedata/eeg/IC_trn_P09_F_3.bdf', ...
'sourcedata/eeg/IC_trn_P09_F_4.bdf', ...
'sourcedata/eeg/IC_trn_P09_O_1.bdf', ...
'sourcedata/eeg/IC_trn_P09_O_2.bdf', ...
'sourcedata/eeg/IC_trn_P09_O_3.bdf', ...
'sourcedata/eeg/IC_trn_P09_O_4.bdf'}, ...
'sub-s09/eeg/sub-s09_task-faceFO_eeg.set');
diary 'sourcedata/eeg/sub-s10.log';
%% CHECK FOR OUTPUT PATH AND CRETAE IF NECESSARY
system('mkdir -p sub-s10/eeg');
eeg_init({'sourcedata/eeg/IC_trn_P10_F_1.bdf', ...
'sourcedata/eeg/IC_trn_P10_F_2.bdf', ...
'sourcedata/eeg/IC_trn_P10_F_3.bdf', ...
'sourcedata/eeg/IC_trn_P10_F_4.bdf', ...
'sourcedata/eeg/IC_trn_P10_O_1.bdf', ...
'sourcedata/eeg/IC_trn_P10_O_2.bdf', ...
'sourcedata/eeg/IC_trn_P10_O_3.bdf', ...
'sourcedata/eeg/IC_trn_P10_O_4.bdf'}, ...
'sub-s10/eeg/sub-s10_task-faceFO_eeg.set');
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment