function []=stat_threshold_gui(Volume); col1 = [0.2 0.6 0.9]; col2 = col1*0.9; col3 = [1 1 1]; col4 = col2*1; col5 = col1*.8; Volume.T_Thresh.Status = 'OK'; Volume.LocMax.Status = 'OK'; Volume.LocMax.Input.filename=[]; h0 = figure('Units','normalized', ... 'Color',col1, ... 'Name','Stat_Threshold', ... 'NumberTitle','off', ... 'Resize','off', ... 'Position',[0.3 0.4 0.4 0.3], ... 'Tag','fmrilm'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col5, ... 'CallBack', ['stat_threshold_gui_cb;Volume=get(gcf,''UserData'');if (Volume.T_Thresh.Status(1:2) == ''OK'')& (Volume.LocMax.Status(1:2) == ''OK'');delete(gcf);stat_threshold_prog(Volume);return; else; if (Volume.T_Thresh.Status(1:2) ~= ''OK'') errordlg(Volume.LocMax.Status,''Error'');end;if (Volume.T_Thresh.Status(1:2) ~= ''OK'') errordlg(Volume.LocMax.Status,''Error'');end;end'], ... 'ListboxTop',0, ... 'Position',[0.87 0.02 0.10 0.06], ... 'String','Accept', ... 'Style','pushbutton', ... 'Tag','Push1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col5, ... 'CallBack', 'Volume=get(gcf,''UserData'');delete(gcf);set(Volume.fig,''Visible'',''on'');return;', ... 'ListboxTop',0, ... 'Position',[0.75 0.02 0.10 0.06], ... 'String','Back', ... 'Style','pushbutton', ... 'Tag','Push1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Callback','stat_threshold_gui_cb', ... 'ListboxTop',0, ... 'Position',[0.20 0.87 0.30 0.05], ... 'String','Stat_Threshold', ... 'Style','checkbox', ... 'Tag','Tstat', ... 'Value',0); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Callback','stat_threshold_gui_cb', ... 'ListboxTop',0, ... 'Position',[0.60 0.87 0.15 0.05], ... 'String','LocMax', ... 'Style','checkbox', ... 'Tag','LocMax', ... 'Value',0); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.10 0.75 0.15 0.07], ... 'String','Search Volume', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.10 0.65 0.15 0.07], ... 'String','1000000', ... 'Style','edit', ... 'Tag','SearchVolume'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.30 0.75 0.15 0.07], ... 'String','Voxel Volume', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.30 0.65 0.15 0.07], ... 'String','1', ... 'Style','edit', ... 'Tag','VoxelVolume'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.50 0.75 0.15 0.07], ... 'String','FWHM', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.50 0.65 0.15 0.07], ... 'String','0', ... 'Style','edit', ... 'Tag','FWHM'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.70 0.75 0.15 0.07], ... 'String','Df', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.70 0.65 0.15 0.07], ... 'String','Inf', ... 'Style','edit', ... 'Tag','Df'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.10 0.50 0.15 0.07], ... 'String','P_val_Peak', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.10 0.40 0.15 0.07], ... 'String','0.05', ... 'Style','edit', ... 'Tag','P_val_peak'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.30 0.50 0.15 0.07], ... 'String','Cluster Thresh', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.30 0.40 0.15 0.07], ... 'String','0.001', ... 'Style','edit', ... 'Tag','ClusterThresh'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.50 0.50 0.15 0.07], ... 'String','P_val_extent', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.50 0.40 0.15 0.07], ... 'String','0.05', ... 'Style','edit', ... 'Tag','P_val_extent'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.70 0.50 0.15 0.07], ... 'String','Dimension', ... 'Style','text', ... 'Tag','StaticText1'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.70 0.40 0.15 0.07], ... 'String','3', ... 'Style','edit', ... 'Tag','Dim'); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Callback','stat_threshold_gui_cb',... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.10 0.25 0.15 0.05], ... 'String','Input File', ... 'Style','pushbutton', ... 'Tag','LocMaxInput', ... 'Value',0); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.27 0.25 0.63 0.05], ... 'String','', ... 'Style','text', ... 'Tag','LocMaxInputFile', ... 'Value',0); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Callback','set(findobj(gcf,''Tag'',''LocMax_calc''),''Value'',1);set(findobj(gcf,''Tag'',''LocMax_inp''),''Value'',0);set(findobj(gcf,''Tag'',''LocMax_val''),''Enable'',''off'');', ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.10 0.13 0.32 0.05], ... 'String','LocMax : Stat Threshold', ... 'Style','radiobutton', ... 'Tag','LocMax_calc', ... 'Value',0); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col4, ... 'Callback','set(findobj(gcf,''Tag'',''LocMax_inp''),''Value'',1);set(findobj(gcf,''Tag'',''LocMax_calc''),''Value'',0);set(findobj(gcf,''Tag'',''LocMax_val''),''Enable'',''on'');', ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.45 0.13 0.23 0.05], ... 'String','LocMax : Value', ... 'Style','radiobutton', ... 'Tag','LocMax_inp', ... 'Value',0); h1 = uicontrol('Parent',h0, ... 'Units','normalized', ... 'BackgroundColor',col3, ... 'Enable', 'off', ... 'ListboxTop',0, ... 'Position',[0.70 0.13 0.20 0.06], ... 'String','3', ... 'Style','edit', ... 'Tag','LocMax_val', ... 'Value',0); h1 = uimenu(gcf,'Label','Related Papers'); uimenu(h1,'Label','Worsley et al. (2000)','CallBack','web(''http://www.math.mcgill.ca/keith/HBM2000/HBM2000.html'',''-browser'');'); uimenu(h1,'Label','Worsley et al. (2001)','CallBack','web(''http://www.math.mcgill.ca/keith/fmristat_paper/fmristat.pdf'',''-browser'');'); uimenu(h1,'Label','Liao et al. (2001)','CallBack','web(''http://www.math.mcgill.ca/keith/delay/delay.pdf'',''-browser'');'); h1 = uimenu(gcf,'Label','Related WebPages'); uimenu(h1,'Label','fMRIstat Web','CallBack','web(''http://www.math.mcgill.ca/keith/fmristat/'',''-browser'');'); uimenu(h1,'Label','fMRI at the BIC','CallBack','web(''http://www.math.mcgill.ca/~vali/fmri/'',''-browser'');'); set(gcf,'UserData',Volume); stat_threshold_gui_cb;