Hello CONN community,
I am testing out implementation of the conn_batch command, and am running into an error when trying to give a name to my user defined contrast (Note I receive this error on both v19c and today's v20b release). All other steps (batch.Setup - batch.Analysis) run without problem, but when I get to batch.Results, if I run the following:
%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%Level 2 Seed/ROI Results
batch.Results.name = 'Test_ROI_to_ROI_Analysis';
batch.Results.display = 1;
[b]batch.Results.saveas = {'SEED_HC_vs_PSD'};[/b]
batch.Results.between_subjects.effect_names = {'HC','SZ','SCA','BPD','Age','meanFD'};
batch.Results.between_subjects.contrast = [1 -0.33 -0.33 -0.33 0 0];
batch.Results.overwrite = 'Yes';
batch.Results.done = 1;
%%%%%%%%%%%%%%%%%%%%%%%%%%
I get the following error:
[color=#ff0000]%%%%%%%%%%%%%%%%%%%%%%%%%%[/color]
[color=#ff0000]Undefined function or variable 'descrip'.[/color]
[color=#ff0000]Error in conn_contrastmanager/conn_contrastmanager_update (line 93)[/color]
[color=#ff0000]if isempty(descrip), nameext=sprintf('%s',name);[/color]
[color=#ff0000]Error in conn_contrastmanager (line 17)[/color]
[color=#ff0000]else conn_contrastmanager_update(str,varargin{:});[/color]
[color=#ff0000]Error in conn_batch (line 1761)[/color]
[color=#ff0000]conn_contrastmanager('add',0,batch.Results.saveas);[/color]
[color=#ff0000]Error in conn_batch (line 1746)[/color]
[color=#ff0000]conn_batch(batchtemp);[/color]
[color=#ff0000]Error in conn_process (line 68)[/color]
[color=#ff0000]case 'batch', conn_batch(varargin{:});[/color]
[color=#ff0000]%%%%%%%%%%%%%%%%%%%%%%%%%[/color]
[color=#ff0000]<font color="#000000">However, everything runs without error if I comment out the [b]batch.Results.saveas = {'SEED_HC_vs_PSD'};[/b] line.[/color]</font>
Also note that adding a description to the subject effect variables (i.e. [b]batch.Setup.subjects.descrip[/b]) does not fix the aforementioned error.
[color=#ff0000]<font color="#000000">Any help with this would be greatly appreciated. [/color]</font>
[color=#ff0000]<font color="#000000">Below you will find the full syntax for the batch structure, in case this is an upstream issue. [/color]</font>
[color=#ff0000]<font color="#000000">Thank you, [/color]</font>
[color=#ff0000]<font color="#000000">David [/color]</font>
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
clear batch;
batch.filename = fullfile(results_o_dir,'MACIP_CONN_ANALYSIS.mat');
batch.parallel.N = NSUBJECTS;
batch.parallel.profile='Background process (Unix,Mac)';
batch.Setup.isnew = 1;
batch.Setup.nsubjects = NSUBJECTS;
batch.Setup.RT = 0.46;
batch.Setup.functionals = repmat({{}},[NSUBJECTS,1]);
for nsub = 1:NSUBJECTS
batch.Setup.functionals{nsub}{1} = FUNCTIONAL_FILE{nsub};
end
batch.Setup.structurals = STRUCTURAL_FILE;
batch.Setup.secondarydatasets.functionals_type = 2;
batch.Setup.conditions.names = {'rest'};
for ncond=1
for nsub=1:NSUBJECTS
for nses=1
batch.Setup.conditions.onsets{ncond}{nsub}{nses} = 0;
batch.Setup.conditions.durations{ncond}{nsub}{nses} = inf;
end
end
end
batch.Setup.rois.names = {'ATLAS_TLRC'};
batch.Setup.rois.files{1} = ROIFILE;
batch.Setup.rois.multiplelabels = 1;
batch.Setup.rois.dataset = 1;
batch.Setup.preprocessing.steps = {'functional_smooth','functional_label_as_smoothed'};
batch.Setup.preprocessing.fwhm = 6;
batch.Setup.analyses = [1,2,3];
batch.Setup.voxelmask = 1;
batch.Setup.voxelmaskfile = ANALYSIS_MASK_FILE;
batch.Setup.voxelresolution = 1;
batch.Setup.analysisunits = 2;
batch.Setup.subjects.group_names = {'HC','SZ','SCA','BPD'};
batch.Setup.subjects.groups = MACIP_DATA.DSM_DX;
batch.Setup.subjects.effect_names = {'Age','meanFD'};
batch.Setup.subjects.effects = {MACIP_DATA.Age,MACIP_DATA.REST_meanFD};
batch.Setup.done = 1;
batch.Setup.overwrite = 'Yes';
%%Denoising step
batch.Denoising.filter = [0.01, 0.1];
batch.Denoising.detrending = 0;
batch.Denoising.despiking = 0;
batch.Denoising.counfounds.names = {''};
batch.Denoising.done = 1;
batch.Denoising.overwirte = 'Yes';
%%%Level-1 ROI-to-ROI and seed-to-voxel analysis step
batch.Analysis.name = 'Test_ROI_to_ROI_Analysis';
batch.Analysis.measure = 1;
batch.Analysis.weight = 2;
batch.Analysis.modulation = 0;
batch.Analysis.type = 3;
batch.Analysis.done = 1;
batch.Analysis.overwrite = 'Yes';
%%%%Level-1 voxel-to-voxel ICA analysis
batch.vvAnalysis.name = 'Test_ICA_Analysis';
batch.vvAnalysis.measures.names = 'group-ICA';
batch.vvAnalysis.measures.factors = 20;
batch.vvAnalysis.measures.kernelsupport = 8;
batch.vvAnalysis.measures.norm = 1;
batch.vvAnalysis.measures.options = 'GICA3';
batch.vvAnalysis.measures.dimensions = 64;
batch.vvAnalysis.done = 1;
batch.vvAnalysis.overwrite = 'Yes';
%%%%Level-2 Seed/ROI Analyses
batch.Results.name = 'Test_ROI_to_ROI_Analysis';
batch.Results.display = 1;
batch.Results.saveas = {'SEED_HC_vs_PSD'};
batch.Results.between_subjects.effect_names = {'HC','SZ','SCA','BPD','Age','meanFD'};
batch.Results.between_subjects.contrast = [1 -0.33 -0.33 -0.33 0 0];
batch.Results.overwrite = 'Yes';
batch.Results.done = 1;
% %%%%Level-2 Voxelwise/ICA Analyses
batch.vvResults.name = 'Test_ICA_Analysis';
batch.vvResults.display = 1;
batch.vvResults.saveas = {'ICA_HC_vs_PSD'};
batch.vvResults.between_subjects.effect_names = {'HC','SZ','SCA','BPD','Age','meanFD'};
batch.vvResults.between_subjects.contrast = [1 -0.33 -0.33 -0.33 0 0 ];
batch.vvResults.overwrite = 'Yes';
batch.vvResults.done = 1;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
[color=#ff0000]<font color="#000000">
[/color]</font>
I am testing out implementation of the conn_batch command, and am running into an error when trying to give a name to my user defined contrast (Note I receive this error on both v19c and today's v20b release). All other steps (batch.Setup - batch.Analysis) run without problem, but when I get to batch.Results, if I run the following:
%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%Level 2 Seed/ROI Results
batch.Results.name = 'Test_ROI_to_ROI_Analysis';
batch.Results.display = 1;
[b]batch.Results.saveas = {'SEED_HC_vs_PSD'};[/b]
batch.Results.between_subjects.effect_names = {'HC','SZ','SCA','BPD','Age','meanFD'};
batch.Results.between_subjects.contrast = [1 -0.33 -0.33 -0.33 0 0];
batch.Results.overwrite = 'Yes';
batch.Results.done = 1;
%%%%%%%%%%%%%%%%%%%%%%%%%%
I get the following error:
[color=#ff0000]%%%%%%%%%%%%%%%%%%%%%%%%%%[/color]
[color=#ff0000]Undefined function or variable 'descrip'.[/color]
[color=#ff0000]Error in conn_contrastmanager/conn_contrastmanager_update (line 93)[/color]
[color=#ff0000]if isempty(descrip), nameext=sprintf('%s',name);[/color]
[color=#ff0000]Error in conn_contrastmanager (line 17)[/color]
[color=#ff0000]else conn_contrastmanager_update(str,varargin{:});[/color]
[color=#ff0000]Error in conn_batch (line 1761)[/color]
[color=#ff0000]conn_contrastmanager('add',0,batch.Results.saveas);[/color]
[color=#ff0000]Error in conn_batch (line 1746)[/color]
[color=#ff0000]conn_batch(batchtemp);[/color]
[color=#ff0000]Error in conn_process (line 68)[/color]
[color=#ff0000]case 'batch', conn_batch(varargin{:});[/color]
[color=#ff0000]%%%%%%%%%%%%%%%%%%%%%%%%%[/color]
[color=#ff0000]<font color="#000000">However, everything runs without error if I comment out the [b]batch.Results.saveas = {'SEED_HC_vs_PSD'};[/b] line.[/color]</font>
Also note that adding a description to the subject effect variables (i.e. [b]batch.Setup.subjects.descrip[/b]) does not fix the aforementioned error.
[color=#ff0000]<font color="#000000">Any help with this would be greatly appreciated. [/color]</font>
[color=#ff0000]<font color="#000000">Below you will find the full syntax for the batch structure, in case this is an upstream issue. [/color]</font>
[color=#ff0000]<font color="#000000">Thank you, [/color]</font>
[color=#ff0000]<font color="#000000">David [/color]</font>
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
clear batch;
batch.filename = fullfile(results_o_dir,'MACIP_CONN_ANALYSIS.mat');
batch.parallel.N = NSUBJECTS;
batch.parallel.profile='Background process (Unix,Mac)';
batch.Setup.isnew = 1;
batch.Setup.nsubjects = NSUBJECTS;
batch.Setup.RT = 0.46;
batch.Setup.functionals = repmat({{}},[NSUBJECTS,1]);
for nsub = 1:NSUBJECTS
batch.Setup.functionals{nsub}{1} = FUNCTIONAL_FILE{nsub};
end
batch.Setup.structurals = STRUCTURAL_FILE;
batch.Setup.secondarydatasets.functionals_type = 2;
batch.Setup.conditions.names = {'rest'};
for ncond=1
for nsub=1:NSUBJECTS
for nses=1
batch.Setup.conditions.onsets{ncond}{nsub}{nses} = 0;
batch.Setup.conditions.durations{ncond}{nsub}{nses} = inf;
end
end
end
batch.Setup.rois.names = {'ATLAS_TLRC'};
batch.Setup.rois.files{1} = ROIFILE;
batch.Setup.rois.multiplelabels = 1;
batch.Setup.rois.dataset = 1;
batch.Setup.preprocessing.steps = {'functional_smooth','functional_label_as_smoothed'};
batch.Setup.preprocessing.fwhm = 6;
batch.Setup.analyses = [1,2,3];
batch.Setup.voxelmask = 1;
batch.Setup.voxelmaskfile = ANALYSIS_MASK_FILE;
batch.Setup.voxelresolution = 1;
batch.Setup.analysisunits = 2;
batch.Setup.subjects.group_names = {'HC','SZ','SCA','BPD'};
batch.Setup.subjects.groups = MACIP_DATA.DSM_DX;
batch.Setup.subjects.effect_names = {'Age','meanFD'};
batch.Setup.subjects.effects = {MACIP_DATA.Age,MACIP_DATA.REST_meanFD};
batch.Setup.done = 1;
batch.Setup.overwrite = 'Yes';
%%Denoising step
batch.Denoising.filter = [0.01, 0.1];
batch.Denoising.detrending = 0;
batch.Denoising.despiking = 0;
batch.Denoising.counfounds.names = {''};
batch.Denoising.done = 1;
batch.Denoising.overwirte = 'Yes';
%%%Level-1 ROI-to-ROI and seed-to-voxel analysis step
batch.Analysis.name = 'Test_ROI_to_ROI_Analysis';
batch.Analysis.measure = 1;
batch.Analysis.weight = 2;
batch.Analysis.modulation = 0;
batch.Analysis.type = 3;
batch.Analysis.done = 1;
batch.Analysis.overwrite = 'Yes';
%%%%Level-1 voxel-to-voxel ICA analysis
batch.vvAnalysis.name = 'Test_ICA_Analysis';
batch.vvAnalysis.measures.names = 'group-ICA';
batch.vvAnalysis.measures.factors = 20;
batch.vvAnalysis.measures.kernelsupport = 8;
batch.vvAnalysis.measures.norm = 1;
batch.vvAnalysis.measures.options = 'GICA3';
batch.vvAnalysis.measures.dimensions = 64;
batch.vvAnalysis.done = 1;
batch.vvAnalysis.overwrite = 'Yes';
%%%%Level-2 Seed/ROI Analyses
batch.Results.name = 'Test_ROI_to_ROI_Analysis';
batch.Results.display = 1;
batch.Results.saveas = {'SEED_HC_vs_PSD'};
batch.Results.between_subjects.effect_names = {'HC','SZ','SCA','BPD','Age','meanFD'};
batch.Results.between_subjects.contrast = [1 -0.33 -0.33 -0.33 0 0];
batch.Results.overwrite = 'Yes';
batch.Results.done = 1;
% %%%%Level-2 Voxelwise/ICA Analyses
batch.vvResults.name = 'Test_ICA_Analysis';
batch.vvResults.display = 1;
batch.vvResults.saveas = {'ICA_HC_vs_PSD'};
batch.vvResults.between_subjects.effect_names = {'HC','SZ','SCA','BPD','Age','meanFD'};
batch.vvResults.between_subjects.contrast = [1 -0.33 -0.33 -0.33 0 0 ];
batch.vvResults.overwrite = 'Yes';
batch.vvResults.done = 1;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
[color=#ff0000]<font color="#000000">
[/color]</font>