forked from LIMO-EEG-Toolbox/limo_tools
-
Notifications
You must be signed in to change notification settings - Fork 1
/
limo_central_tendency_questdlg.m
170 lines (128 loc) · 4.65 KB
/
limo_central_tendency_questdlg.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
function varargout = limo_central_tendency_questdlg(varargin)
% LIMO_CENTRAL_TENDENCY_QUESTDLG M-file for limo_central_tendency_questdlg.fig
% GUI of LIMO_eeg toolbox
% Called by limo_central_tendency_and)ci.m
% created using GUIDE
% cyril pernet 12-03-2010 v1
% -----------------------------
% Copyright (C) LIMO Team 2010
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @limo_central_tendency_questdlg_OpeningFcn, ...
'gui_OutputFcn', @limo_central_tendency_questdlg_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before limo_central_tendency_questdlg is made visible.
function limo_central_tendency_questdlg_OpeningFcn(hObject, eventdata, handles, varargin)
% Choose default command line output for limo_central_tendency_questdlg
handles.output = hObject;
handles.Estimator1 = [];
handles.Estimator2 = [];
% Update handles structure
guidata(hObject, handles);
uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = limo_central_tendency_questdlg_OutputFcn(hObject, eventdata, handles)
if isempty(handles.Estimator1) && isempty(handles.Estimator2)
varargout{1} = [] ;
varargout{2} = [] ;
else
varargout{1} = handles.Estimator1;
varargout{2} = handles.Estimator2;
end
delete(handles.figure1)
% -------------------------------------------------------------------------
% Intra-subject panel
% -------------------------------------------------------------------------
% --- Executes on button press in mean_1.
function mean1_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator1 = 'Mean';
end
guidata(hObject, handles);
% --- Executes on button press in trimmed_mean1.
function trimmed_mean1_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator1 = 'Trimmed mean';
end
guidata(hObject, handles);
% --- Executes on button press in harrell_davis1.
function harrell_davis1_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator1 = 'HD';
end
guidata(hObject, handles);
% --- Executes on button press in median1.
function median1_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator1 = 'Median';
end
guidata(hObject, handles);
% -------------------------------------------------------------------------
% Inter-subject panel
% -------------------------------------------------------------------------
% --- Executes on button press in mean2.
function mean2_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator2 = 'Mean';
end
guidata(hObject, handles);
% --- Executes on button press in trimmed_mean2.
function trimmed_mean2_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator2 = 'Trimmed mean';
end
guidata(hObject, handles);
% --- Executes on button press in harrell_davis2.
function harrell_davis2_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator2 = 'HD';
end
guidata(hObject, handles);
% --- Executes on button press in median2.
function median2_Callback(hObject, eventdata, handles)
status = get(hObject,'Value');
if status == 1
handles.Estimator2 = 'Median';
end
guidata(hObject, handles);
% -------------------------------------------------------------------------
% Other buttons
% -------------------------------------------------------------------------
% --- Executes on button press in quit.
function quit_Callback(hObject, eventdata, handles)
uiresume
guidata(hObject, handles);
clear all
% --- Executes on button press in help.
function help_Callback(hObject, eventdata, handles)
origin = which('limo_eeg'); origin = origin(1:end-10);
origin = sprintf('%shelp',origin); cd(origin)
web(['file://' which('limo_central_tendency_questdlg.html')]);
cd (handles.dir)
% --- Executes on button press in done.
function done_Callback(hObject, eventdata, handles)
if ~isempty(handles.Estimator1) && ~isempty(handles.Estimator2)
varargout{1} = handles.Estimator1;
varargout{2} = handles.Estimator2;
uiresume
guidata(hObject, handles);
end