Skip to content

Commit

Permalink
SPM8 r3164
Browse files Browse the repository at this point in the history
  • Loading branch information
SPMcentral committed May 29, 2009
1 parent c6d6c5c commit f4c048c
Show file tree
Hide file tree
Showing 449 changed files with 10,047 additions and 3,337 deletions.
Binary file modified @file_array/private/file2mat.mexmaci
Binary file not shown.
Binary file added @file_array/private/file2mat.mexmaci64
Binary file not shown.
Binary file modified @file_array/private/mat2file.mexmaci
Binary file not shown.
Binary file added @file_array/private/mat2file.mexmaci64
Binary file not shown.
16 changes: 14 additions & 2 deletions @gifti/export.m
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% Guillaume Flandin
% $Id: export.m 2587 2009-01-05 12:11:39Z vladimir $
% $Id: export.m 3081 2009-04-22 20:15:38Z guillaume $

if numel(this) > 1, warning('Only handle scalar objects yet.'); end

Expand All @@ -18,6 +18,18 @@
case 'matlab'
s = struct(this);

case 'patch'
if isfield(this,'vertices')
s.vertices = subsref(this, substruct('.', 'vertices'));
end
if isfield(this,'faces')
s.faces = subsref(this, substruct('.', 'faces'));
end
if isfield(this,'cdata')
s.facevertexcdata = subsref(this, substruct('.', 'cdata'));
end
try, s; catch, s = struct([]); end

case {'fieldtrip', 'ft'}
s = struct('tri',[], 'pnt',[]);
if isfield(this,'vertices')
Expand All @@ -32,7 +44,7 @@
if isfield(this,'vertices')
s.vert = double(subsref(this, substruct('.', 'vertices')));
end
if isfield(this,'faces')
if isfield(this,'faces')
s.face = uint16(subsref(this, substruct('.', 'faces')));
end

Expand Down
4 changes: 2 additions & 2 deletions @meeg/condlist.m
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% Vladimir Litvak
% $Id: condlist.m 2877 2009-03-13 15:56:08Z vladimir $
% $Id: condlist.m 3046 2009-04-02 14:28:31Z vladimir $

res = getset(this, 'trials', 'label');
if ~iscell(res)
Expand All @@ -24,7 +24,7 @@
if numel(res)>1 && isfield(this.other, 'condlist') &&...
iscell(this.other.condlist) && ~isempty(this.other.condlist)
[sel1, sel2] = spm_match_str(this.other.condlist, res);
res = res([sel2 setdiff(1:numel(res), sel2)]);
res = res([sel2(:)' setdiff(1:numel(res), sel2)]);
end
else
if iscell(newcondlist) && ~isempty(intersect(newcondlist, res))
Expand Down
10 changes: 7 additions & 3 deletions @meeg/pickconditions.m
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,20 @@
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% Stefan Kiebel
% $Id: pickconditions.m 2448 2008-11-07 16:56:07Z vladimir $
% $Id: pickconditions.m 3146 2009-05-26 09:54:23Z vladimir $

if nargin<3
rejectbad = 1;
end

c = conditions(this);

res = strmatch(deblank(label), deblank(c), 'exact');

if isa(label, 'char')
label = {label};
end

res = find(ismember(c, label));

if rejectbad && ~isempty(res)
res = res(~reject(this, res));
end
13 changes: 12 additions & 1 deletion @meeg/private/checkmeeg.m
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% Vladimir Litvak
% $Id: checkmeeg.m 2978 2009-03-27 14:43:08Z guillaume $
% $Id: checkmeeg.m 3068 2009-04-20 17:21:57Z vladimir $

if nargin==1
option = 'basic';
Expand Down Expand Up @@ -255,6 +255,17 @@

if ~isfield(meegstruct, 'sensors')
meegstruct.sensors = struct([]);
else
if isfield(meegstruct.sensors, 'eeg')
if isempty(meegstruct.sensors.eeg) || isempty(meegstruct.sensors.eeg.pnt)
meegstruct.sensors = rmfield(meegstruct.sensors, 'eeg');
end
end
if isfield(meegstruct.sensors, 'meg')
if isempty(meegstruct.sensors.meg) || isempty(meegstruct.sensors.meg.pnt)
meegstruct.sensors = rmfield(meegstruct.sensors, 'meg');
end
end
end

if ~isfield(meegstruct, 'fiducials')
Expand Down
6 changes: 3 additions & 3 deletions @nifti/private/decode_qform0.m
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

%
% $Id: decode_qform0.m 1143 2008-02-07 19:33:33Z spm $
% $Id: decode_qform0.m 3131 2009-05-18 15:54:10Z guillaume $


dim = double(hdr.dim);
Expand All @@ -15,9 +15,9 @@
%disp('The images are in a form whereby it is not possible to');
%disp('tell the left and right sides of the brain apart.');
%if flp,
% disp('They are assumed to be stored right-handed.');
%else
% disp('They are assumed to be stored left-handed.');
%else
% disp('They are assumed to be stored right-handed.');
%end;
%disp('------------------------------------------------------');

Expand Down
Binary file modified @xmltree/private/xml_findstr.mexmaci
Binary file not shown.
Binary file added @xmltree/private/xml_findstr.mexmaci64
Binary file not shown.
6 changes: 3 additions & 3 deletions Contents.m
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
% Statistical Parametric Mapping
% Version 3042 (SPM8) 02-Apr-2009
% Version 3164 (SPM8) 29-May-09
%__________________________________________________________________________
% ___ ____ __ __
% / __)( _ \( \/ )
Expand All @@ -11,7 +11,7 @@
%
% SPM8 is written for MATLAB 7.1 (R14SP3) onwards under Windows and Unix.
% ( Compiled binaries of external C-MEX functions are provided for: )
% ( Windows (32 and 64 bit), Linux (32 and 64 bit) and Mac (32 bit) )
% ( Windows (32 and 64 bit), Linux (32 and 64 bit) and Mac (32 and 64 bit))
%
% See spm.man for details of this release.
% See README.txt for information on installation and getting started.
Expand Down Expand Up @@ -42,7 +42,7 @@
%__________________________________________________________________________
% Copyright (C) 1991,1994-2003,2005-2009 Wellcome Trust Centre for Neuroimaging

% $Id: Contents.m 3041 2009-04-02 10:14:17Z guillaume $
% $Id: Contents.m 3163 2009-05-29 14:04:55Z guillaume $

%==========================================================================
% PROGRAMMERS NOTE:
Expand Down
4 changes: 2 additions & 2 deletions config/spm_cfg_eeg_convert.m
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% Stefan Kiebel
% $Id: spm_cfg_eeg_convert.m 2720 2009-02-09 19:50:46Z vladimir $
% $Id: spm_cfg_eeg_convert.m 3059 2009-04-15 18:09:13Z guillaume $

dataset = cfg_files;
dataset.tag = 'dataset';
Expand Down Expand Up @@ -207,8 +207,8 @@

S.usetrials = 0;
[S.trl, S.conditionlabel] = spm_eeg_definetrial(S);

end
S.continuous = 0;
end

if isfield(S.channels, 'chanmeg')
Expand Down
30 changes: 30 additions & 0 deletions config/spm_cfg_eeg_tf_rescale.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
function S = spm_cfg_eeg_tf_rescale
% configuration file for rescaling spectrograms
%_______________________________________________________________________
% Copyright (C) 2009 Wellcome Trust Centre for Neuroimaging

% Will Penny
% $Id: spm_cfg_eeg_tf_rescale.m 3090 2009-04-29 17:30:05Z will $

Fname = cfg_files;
Fname.tag = 'Fname';
Fname.name = 'File Names';
Fname.filter = 'mat';
Fname.num = [1 inf];
Fname.help = {'Select the M/EEG mat file.'};


S = cfg_exbranch;
S.tag = 'eeg_tf_rescale';
S.name = 'M/EEG TF Rescale';
S.val = {Fname};
S.help = {'Rescale spectrogram using eg Log Ratio operator'};
S.prog = @eeg_tf_rescale;
S.modality = {'EEG'};


function out = eeg_tf_rescale(job)
% construct the S struct
S = job;
S.Fname = strvcat(job.Fname);

20 changes: 10 additions & 10 deletions config/spm_cfg_factorial_design.m
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
function factorial_design = spm_cfg_factorial_design
% SPM Configuration file
% automatically generated by the MATLABBATCH utility function GENCODE
% SPM Configuration file for 2nd-level models
%_______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% $Id: spm_cfg_factorial_design.m 2975 2009-03-26 21:43:31Z guillaume $
% Will Penny
% $Id: spm_cfg_factorial_design.m 3067 2009-04-20 13:58:07Z guillaume $

rev = '$Rev: 2975 $';
% ---------------------------------------------------------------------
% dir Directory
% ---------------------------------------------------------------------
Expand All @@ -17,6 +16,7 @@
dir.filter = 'dir';
dir.ufilter = '.*';
dir.num = [1 1];

% ---------------------------------------------------------------------
% scans Scans
% ---------------------------------------------------------------------
Expand All @@ -35,6 +35,7 @@
t1.name = 'One-sample t-test';
t1.val = {scans };
t1.help = {''};

% ---------------------------------------------------------------------
% scans1 Group 1 scans
% ---------------------------------------------------------------------
Expand Down Expand Up @@ -144,6 +145,7 @@
t2.name = 'Two-sample t-test';
t2.val = {scans1 scans2 dept variance gmsca ancova };
t2.help = {''};

% ---------------------------------------------------------------------
% scans Scans [1,2]
% ---------------------------------------------------------------------
Expand All @@ -168,20 +170,18 @@
generic = cfg_repeat;
generic.tag = 'generic';
generic.name = 'Pairs';
generic.help = {
''
''
}';
generic.values = {pair };
generic.help = {''};
generic.values = {pair};
generic.num = [1 Inf];
% ---------------------------------------------------------------------
% pt Paired t-test
% ---------------------------------------------------------------------
pt = cfg_branch;
pt.tag = 'pt';
pt.name = 'Paired t-test';
pt.val = {generic dept variance gmsca ancova };
pt.val = {generic gmsca ancova};
pt.help = {''};

% ---------------------------------------------------------------------
% scans Scans
% ---------------------------------------------------------------------
Expand Down
46 changes: 23 additions & 23 deletions config/spm_cfg_preproc.m
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
%_______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% $Id: spm_cfg_preproc.m 2834 2009-03-06 17:57:50Z john $
% $Id: spm_cfg_preproc.m 3124 2009-05-18 08:13:52Z volkmar $

rev = '$Rev: 2834 $';
rev = '$Rev: 3124 $';
% ---------------------------------------------------------------------
% data Data
% ---------------------------------------------------------------------
Expand Down Expand Up @@ -311,9 +311,6 @@
%------------------------------------------------------------------------
function dep = vout(job)
opts = job.output;
% This depends on job contents, which may not be present when virtual
% outputs are calculated.
sopts = [opts.GM;opts.WM;opts.CSF];

cdep(1) = cfg_dep;
cdep(1).sname = 'Norm Params Subj->MNI';
Expand All @@ -329,25 +326,28 @@
cdep(end).src_output = substruct('()',{1}, '.','biascorr','()',{':'});
cdep(end).tgt_spec = cfg_findspec({{'filter','image','strtype','e'}});
end;
sonames = {'GM','WM','CSF'};
for k1=1:3,
if sopts(k1,3),
cdep(end+1) = cfg_dep;
cdep(end).sname = sprintf('c%d Images',k1);
cdep(end).src_output = substruct('()',{1}, '.',sprintf('c%d',k1),'()',{':'});
cdep(end).tgt_spec = cfg_findspec({{'filter','image','strtype','e'}});
end;
if sopts(k1,2),
cdep(end+1) = cfg_dep;
cdep(end).sname = sprintf('wc%d Images',k1);
cdep(end).src_output = substruct('()',{1}, '.',sprintf('wc%d',k1),'()',{':'});
cdep(end).tgt_spec = cfg_findspec({{'filter','image','strtype','e'}});
end;
if sopts(k1,1),
cdep(end+1) = cfg_dep;
cdep(end).sname = sprintf('mwc%d Images',k1);
cdep(end).src_output = substruct('()',{1}, '.',sprintf('mwc%d',k1),'()',{':'});
cdep(end).tgt_spec = cfg_findspec({{'filter','image','strtype','e'}});
end;
if ~strcmp(opts.(sonames{k1}),'<UNDEFINED>')
if opts.(sonames{k1})(3),
cdep(end+1) = cfg_dep;
cdep(end).sname = sprintf('c%d Images',k1);
cdep(end).src_output = substruct('()',{1}, '.',sprintf('c%d',k1),'()',{':'});
cdep(end).tgt_spec = cfg_findspec({{'filter','image','strtype','e'}});
end;
if opts.(sonames{k1})(2),
cdep(end+1) = cfg_dep;
cdep(end).sname = sprintf('wc%d Images',k1);
cdep(end).src_output = substruct('()',{1}, '.',sprintf('wc%d',k1),'()',{':'});
cdep(end).tgt_spec = cfg_findspec({{'filter','image','strtype','e'}});
end;
if opts.(sonames{k1})(1),
cdep(end+1) = cfg_dep;
cdep(end).sname = sprintf('mwc%d Images',k1);
cdep(end).src_output = substruct('()',{1}, '.',sprintf('mwc%d',k1),'()',{':'});
cdep(end).tgt_spec = cfg_findspec({{'filter','image','strtype','e'}});
end;
end
end;
dep = cdep;

Expand Down
26 changes: 23 additions & 3 deletions config/spm_cfg_reorient.m
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
%_______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging

% $Id: spm_cfg_reorient.m 1299 2008-04-03 08:55:09Z volkmar $
% $Id: spm_cfg_reorient.m 3130 2009-05-18 14:41:31Z volkmar $

rev = '$Rev: 1299 $';
rev = '$Rev: 3130 $';
% ---------------------------------------------------------------------
% srcfiles Images to reorient
% ---------------------------------------------------------------------
Expand Down Expand Up @@ -70,13 +70,33 @@
transform.val = {transM };
transform.help = {'Specify reorientation method.'};
transform.values = {transM transprm };
% ---------------------------------------------------------------------
% prefix Filename Prefix
% ---------------------------------------------------------------------
prefix = cfg_entry;
prefix.tag = 'prefix';
prefix.name = 'Filename Prefix';
prefix.help = {['Specify the string to be prepended to the filenames ' ...
'of the reoriented image file(s). If this is left ' ...
'empty, the original files will be overwritten.']};
prefix.strtype = 's';
prefix.num = [0 Inf];
% This should not be hardcoded here
prefix.val = {''};
% Final solution: defaults setting
% prefix.def = @(val)spm_get_defaults('reorient.prefix', val{:});
% The following 3 lines should go into spm_defaults.m
% % Reorient defaults
% %=======================================================================
% defaults.reorient.prefix = ''; % Output filename prefix ('' == overwrite)

% ---------------------------------------------------------------------
% reorient Reorient Images
% ---------------------------------------------------------------------
reorient = cfg_exbranch;
reorient.tag = 'reorient';
reorient.name = 'Reorient Images';
reorient.val = {srcfiles transform };
reorient.val = {srcfiles transform prefix};
reorient.help = {'This facility allows to reorient images in a batch. The reorientation parameters can be given either as a 4x4 matrix or as parameters as defined for spm_matrix.m. The new image orientation will be computed by PRE-multiplying the original orientation matrix with the supplied matrix.'};
reorient.prog = @spm_run_reorient;
reorient.vout = @vout;
Expand Down
Loading

0 comments on commit f4c048c

Please sign in to comment.