Home > functions > job > job_edit_act_dir > job_edit_act_gauss_filter.m

job_edit_act_gauss_filter

PURPOSE ^

Apply Gaussian filter to activity map

SYNOPSIS ^

function job_edit_act_gauss_filter(inst_id)

DESCRIPTION ^

 Apply Gaussian filter to activity map

 --- Syntax
 job_edit_act_gauss_filter(inst_id)

 --- History
 ????-??-?? Taku Yoshioka
 2008-09-04 Taku Yoshioka
 2009-05-01 Taku Yoshioka
  Debug for stacking operation

 Copyright (C) 2011, ATR All Rights Reserved.
 License : New BSD License(see VBMEG_LICENSE.txt)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function job_edit_act_gauss_filter(inst_id)
0002 % Apply Gaussian filter to activity map
0003 %
0004 % --- Syntax
0005 % job_edit_act_gauss_filter(inst_id)
0006 %
0007 % --- History
0008 % ????-??-?? Taku Yoshioka
0009 % 2008-09-04 Taku Yoshioka
0010 % 2009-05-01 Taku Yoshioka
0011 %  Debug for stacking operation
0012 %
0013 % Copyright (C) 2011, ATR All Rights Reserved.
0014 % License : New BSD License(see VBMEG_LICENSE.txt)
0015 
0016 global vbmeg_inst; 
0017 if isempty(vbmeg_inst.editact{inst_id}.xxP), return; end
0018 
0019 %
0020 % Global variables
0021 %
0022 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0023 ed2 = vbmeg_inst.editact{inst_id}.ed2;
0024 nextDD = vbmeg_inst.editact{inst_id}.nextDD;
0025 nextIX = vbmeg_inst.editact{inst_id}.nextIX;
0026 h_fig = vbmeg_inst.editact{inst_id}.h_fig;
0027 
0028 %
0029 % Apply Gaussian filter
0030 %
0031 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0032 set(h_fig,'Pointer','watch');
0033 drawnow;
0034 
0035 % Stack
0036 job_edit_act_stack(inst_id);
0037 xxP = vbmeg_inst.editact{inst_id}.xxP;
0038 
0039 % Radius (FWHM, mm)
0040 R = str2num(get(ed2,'String'));
0041 R = R/(2*sqrt(log(2)))*1e-3;
0042 if R<=0, return; end;
0043 
0044 % Smoothing and registration
0045 I = length(nextDD);
0046 W = job_edit_act_spatial_gauss_filter(nextDD,nextIX,R,2*R,1:I);
0047 xxP{1} = W*xxP{1};
0048 vbmeg_inst.editact{inst_id}.xxP = xxP;
0049 
0050 %
0051 % Update plot
0052 %
0053 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0054 job_edit_act_update_spatialpattern(inst_id);
0055 
0056 set(h_fig,'Pointer','arrow');

Generated on Tue 27-Aug-2013 11:46:04 by m2html © 2005