Dear Nicolas, Sorry for the delay. I could not reproduce this. Could it be that your location variable is transposed? When transposing I get this kind of error. Each point should be a row. Vladimir On Wed, Sep 19, 2012 at 1:57 PM, Nicolas Barascud <[log in to unmask]> wrote: > Dear all, > > I've been trying to restrict my solutions in the group inversion by > providing a .mat file with 2 coordinates (2x3 matrix) and I always get this > error, no matter what I set the 'radius' value to (30, 40, 50, 100 mm) : > > Attempted to access xyz(1,2); index out of bounds because numel(xyz)=1. > > Error in spm_eeg_invert (line 361) > Iv = sum([vert(:,1) - xyz(i,1), ... > > Error in spm_eeg_inv_group (line 208) > D = spm_eeg_invert(D); > > Error in spm_eeg_inv_imag_api>group_Callback (line 480) > spm_eeg_inv_group; > > Error in spm_eeg_inv_imag_api (line 53) > feval(varargin{:}); % FEVAL switchyard > > Error while evaluating uicontrol Callback > > Normal (unrestricted) group inversion works fine. > > Am I doing something wrong here? > > Many thanks, > > --Nicolas