-
Notifications
You must be signed in to change notification settings - Fork 1
/
s_Make_BAIR_Motor_Experiments.m
62 lines (48 loc) · 1.98 KB
/
s_Make_BAIR_Motor_Experiments.m
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
% Make Motor Experiment Files
% Prompt for ExperimentSpecs
[experimentSpecs, whichSite, selectionMade] = bairExperimentSpecs('prompt', true);
if ~selectionMade, return; end
% Which experiment to make?
[experimentType, selectionMade] = bairWhichExperimentMotor();
if ~selectionMade, return; end
% Set some defaults for all the experiments
TR = 0.850; % seconds
stimDiameterDeg = 16.6; % degrees
% Generate stimulus template and set some defaults
if whichSite == 3
experimentSpecs(3,1) = {'BAIR_ACER'};
end
stimParams = stimInitialize(experimentSpecs, whichSite, stimDiameterDeg);
% Find the selected experiment
switch experimentType
case 'BOLDHAND'
stimDurationSeconds = 0.500; % seconds
%onsetTimeMultiple = 0.170; % make the onsets multiple of 170 ms, which is 1/5 of the TR
numberOfRuns = 1;
for runNum = 1:numberOfRuns
% MAKE TASK EXPERIMENT
stimMakeBoldHandExperiment(stimParams, runNum, stimDurationSeconds, TR)
end
case {'GESTURES' 'GESTURESPRACTICE' 'GESTURESLEARNING'}
stimDurationSeconds = 5; % seconds
numberOfRuns = 1;
for runNum = 1:numberOfRuns
% MAKE TASK EXPERIMENT
stimMakeGesturesExperiment(stimParams, runNum, TR, stimDurationSeconds, experimentType);
end
case {'FINGERMAPPINGLEFT', 'FINGERMAPPINGRIGHT'}
numberOfRuns = 1;
for runNum = 1:numberOfRuns
stimMakeFingermappingExperiment(stimParams, runNum, experimentType)
end
case 'BOLDSAT'
stimDurationSeconds = 0.4; % seconds
numberOfRuns = 1;
movementRates = [1/3, .8, 1.3, 1.8]; % Hz
for runNum = 1:numberOfRuns
for ii = 1:length(movementRates)
movementRate = movementRates(ii);
stimMakeBoldSatExperiment(stimParams, runNum, stimDurationSeconds, TR, movementRate,ii)
end
end
end