📄 enter_distributions.m
字号:
function fig = enter_distributions()
% This is the machine-generated representation of a Handle Graphics object
% and its children. Note that handle values may change when these objects
% are re-created. This may cause problems with any callbacks written to
% depend on the value of the handle at the time the object was saved.
% This problem is solved by saving the output as a FIG-file.
%
% To reopen this object, just type the name of the M-file at the MATLAB
% prompt. The M-file and its associated MAT-file must be on your path.
%
% NOTE: certain newer features in MATLAB may not have been saved in this
% M-file due to limitations of this format, which has been superseded by
% FIG-files. Figures which have been annotated using the plot editor tools
% are incompatible with the M-file/MAT-file format, and should be saved as
% FIG-files.
load enter_distributions
v = version;
if (v(1) == '5') %Matlab 5
h0 = figure('Units','characters', ...
'Color',[0.8 0.8 0.8], ...
'Colormap',mat0, ...
'MenuBar','none', ...
'PaperPosition',[52 11 57 35], ...
'PaperUnits','points', ...
'Position',[52 11 57 27], ...
'Tag','Enter Distributions');
else
h0 = figure('Units','characters', ...
'Color',[0.8 0.8 0.8], ...
'Colormap',mat0, ...
'FileName','E:\Work\hw\enter_distributions.m', ...
'MenuBar','none', ...
'PaperPosition',[52 11 57 35], ...
'PaperUnits','points', ...
'Position',[52 11 57 27], ...
'Tag','Enter Distributions', ...
'ToolBar','none');
end
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'ListboxTop',0, ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'Position',[7 4 45 14.65], ...
'Style','frame', ...
'Tag','frmParams');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'ListboxTop',0, ...
'Position',[7 19 45 4], ...
'Style','frame', ...
'Tag','frmClass');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.8 0.8 0.8], ...
'FontSize',12, ...
'FontWeight','bold', ...
'ListboxTop',0, ...
'Position',[4 24 50 2], ...
'String','Manually Enter Distributions', ...
'Style','text', ...
'Tag','txtTitle');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'Callback','enter_distributions_commands(''change_class'',0)', ...
'ListboxTop',0, ...
'Position',[8.5 19.5 20 1], ...
'String','Class 0', ...
'Style','radiobutton', ...
'Tag','rbtClass0', ...
'Value',1);
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'HorizontalAlignment','left', ...
'ListboxTop',0, ...
'Position',[8.5 20.5 20 2], ...
'String','Choose class:', ...
'Style','text', ...
'Tag','txtClass');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'Callback','enter_distributions_commands(''change_class'',1)', ...
'ListboxTop',0, ...
'Position',[30 19.5 20 1], ...
'String','Class 1', ...
'Style','radiobutton', ...
'Tag','rbtClass1');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'Callback','close', ...
'ListboxTop',0, ...
'Position',[42 0.5 10 3], ...
'String','OK', ...
'Tag','pshOK');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'HorizontalAlignment','left', ...
'ListboxTop',0, ...
'Position',[9 15 20 1], ...
'String','Object number:', ...
'Style','text', ...
'Tag','txtParameters');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'HorizontalAlignment','left', ...
'ListboxTop',0, ...
'Position',[9 17 20 1], ...
'String','Distribution type:', ...
'Style','text', ...
'Tag','txtParameters');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'Callback','enter_distributions_commands(''change_type'')', ...
'ListboxTop',0, ...
'Position',[35 16.75 15.5 1.5], ...
'String',mat3, ...
'Style','popupmenu', ...
'Tag','popType', ...
'Value',1);
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'Callback','enter_distributions_commands(''change_object'')', ...
'ListboxTop',0, ...
'Position',[35 14.75 15.5 1.5], ...
'String',mat2, ...
'Style','popupmenu', ...
'Tag','popNumber', ...
'Value',1);
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'ListboxTop',0, ...
'Position',[9 13 30 1], ...
'HorizontalAlignment','left', ...
'String','Weight of the object:', ...
'Style','text', ...
'Tag','txt1');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[1 1 1], ...
'Callback','enter_distributions_commands(''change_parameter'',gcbo)', ...
'ListboxTop',0, ...
'Position',[40 12.75 10.5 1.5], ...
'String','1', ...
'Style','edit', ...
'Tag','txtWeight');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'ListboxTop',0, ...
'HorizontalAlignment','left', ...
'Position',[9 11 30 1], ...
'String','Means of the object:', ...
'Style','text', ...
'Tag','txt2');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[1 1 1], ...
'Callback','enter_distributions_commands(''change_parameter'',gcbo)', ...
'ListboxTop',0, ...
'Position',[35 10.75 7 1.5], ...
'String','0', ...
'Style','edit', ...
'Tag','txtMeanX');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[1 1 1], ...
'Callback','enter_distributions_commands(''change_parameter'',gcbo)', ...
'ListboxTop',0, ...
'Position',[43.5 10.75 7 1.5], ...
'String','0', ...
'Style','edit', ...
'Tag','txtMeanY');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
'ListboxTop',0, ...
'Position',[9 9 29 1], ...
'HorizontalAlignment','left', ...
'String','Covariance of the Gaussian:', ...
'Style','text', ...
'Tag','txtCovCaption');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[1 1 1], ...
'Callback','enter_distributions_commands(''change_parameter'',gcbo)', ...
'ListboxTop',0, ...
'Position',[33 7 10 1.5], ...
'String','0', ...
'Style','edit', ...
'Tag','txtCov12');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[1 1 1], ...
'Callback','enter_distributions_commands(''change_parameter'',gcbo)', ...
'ListboxTop',0, ...
'Position',[20 7 10 1.5], ...
'String','0', ...
'Style','edit', ...
'Tag','txtCov11');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[1 1 1], ...
'Callback','enter_distributions_commands(''change_parameter'',gcbo)', ...
'ListboxTop',0, ...
'Position',[20 5 10 1.5], ...
'String','0', ...
'Style','edit', ...
'Tag','txtCov21');
h1 = uicontrol('Parent',h0, ...
'Units','characters', ...
'BackgroundColor',[1 1 1], ...
'Callback','enter_distributions_commands(''change_parameter'',gcbo)', ...
'ListboxTop',0, ...
'Position',[33 5 10 1.5], ...
'String','0', ...
'Style','edit', ...
'Tag','txtCov22');
if nargout > 0, fig = h0; end
enter_distributions_commands('change_class',0);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -