function [subjects] = select_subjects(crit)

if crit == 0        % exclude poor performers on SD task and people who do not meet inclusion criteria
    subjects{1} = [1:3, 5:7, 14:18, 23, 26, 28:39, 41:43, 49, 77, 78];              % ASD, 6 pp excluded, N = 31
    subjects{2} = [8, 10, 12, 13, 19, 22, 27, 40, 45, 50:61, 63:74];                % HC, 6 pp excluded, N = 33
elseif crit == 1    % include poor performers on SD task, exclude people who do not meet inclusion criteria
    subjects{1} = [1:7, 14:18, 20, 23, 26, 28:39, 41:43, 49, 77, 78];           % ASS, 4 pp excluded, N = 33
    subjects{2} = [8:10, 12, 13, 19, 22, 24, 27, 40, 45, 50:61, 63:74];             % HC, 4 pp excluded, N = 35
elseif crit == 2    % include all participants (exclude no-one)
    subjects{1} = [1:7, 11, 14:18, 20, 23, 25, 26, 28:39, 41:44, 46, 49, 77, 78];   % ASS, all, N = 37
    subjects{2} = [8:10, 12, 13, 19, 21, 22, 24, 27, 40, 45, 50:76];                % HC, all, N = 39
end
    
%% Subject exclusion reasons

% ASD
% 4: did not meet performance criterion on SD task
% 11: ASD diagnosis not confirmed with ADI-R
% 20: did not meet performance criterion on SD task
% 25: ASD diagnosis not confirmed with ADI-R
% 44: Total IQ < 80; WISC below pre-defined cut-off
% 46: did not meet performance criterion on SD task

% HC
% 9: did not meet performance criterion on SD task
% 21: scored within clinical range on the anxiety scale of the CBCL & did not meet performance criterion on SD task
% 24: did not meet performance criterion on SD task
% 62: diagnosed with ASD after conclusion of study
% 75: scored within clinical range on the affective scale of the CBCL & did not meet performance criterion on SD task
% 76: no CBCL

% Other
% 47: empty participant number
% 48: empty participant number


