Skip to content

Commit

Permalink
reestablished basic extrapolation for scalp maps
Browse files Browse the repository at this point in the history
  • Loading branch information
BenjaminBlankertz committed Sep 10, 2012
1 parent d0614de commit e88e27c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions visualization/plot_scalp.m
Original file line number Diff line number Diff line change
Expand Up @@ -183,16 +183,15 @@

if opt.Extrapolation,
wstate= warning('off');
% [xg,yg,zg]= griddata(xe, ye, w, xx, yy, 'invdist');
[xg,yg,zg]= griddata(xe, ye, w, xx, yy);
[xg,yg,zg]= griddata(xe, ye, w, xx, yy, 'v4');
warning(wstate);
margin = maxrad +opt.ContourMargin;
headmask= (sqrt(xg.^2+yg.^2)<=margin);
imaskout= find(~headmask);
zg(imaskout)= NaN;

else
if strcmp(opt.Interpolation, 'invdist'),
if strcmp(opt.Interpolation, 'v4'),
%% get the convex hull from linear Interpolation
[dmy,dmy,zconv]= griddata(xe, ye, w, xx, yy, 'linear');
imaskout= find(isnan(zconv(:)));
Expand Down

0 comments on commit e88e27c

Please sign in to comment.