⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ica.asv

📁 这是盲信号的代码 都已经通过编译了 做这方面的同仁可以参考一下 我觉得蛮惯用的
💻 ASV
📖 第 1 页 / 共 2 页
字号:
  'String','信号预处理', ...
  'FontSize',12,...
  'Style','text', ...
  'Tag','t_white');

pos_l = pos_l + pos_w;
pos_w = 120;
ht_FastICA_whiteStatus = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','', ...
  'Style','text', ...
  'visible','off',...
  'Tag','t_whiteStatus');

% V鋒鋘 v鋖i?pos_t = pos_t - 8;

pos_l = pos_frame(1) + 6;
pos_t = pos_t - pos_h;
pos_w = 150;
b = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Reduced dimension:', ...
  'Style','text', ...
  'visible','off',...
  'Tag','t_4');

pos_l = pos_l + pos_w;
pos_w = 50;
ht_FastICA_newDim = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','', ...
  'Style','text', ...
  'visible','off',...
  'Tag','t_newDim');


% buttons

pos_l = pos_frame(1) + pos_hspace;
pos_w = 110;
pos_h = 30;
pos_t = pos_frame(2) + pos_vspace+10;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb DoPCA', ...
  'Interruptible', 'off', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','去均值', ...
  'FontSize',12,...
  'Tag','b_DoPCA');

pos_l = pos_l + pos_w + pos_hspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb OrigDim', ...
  'Interruptible', 'off', ...
  'Position',[pos_l+15 pos_t pos_w pos_h], ...
  'String','白 化', ...
  'FontSize',12,...
  'Tag','b_OrigDim');

pos_w = 130;
pos_h = 30;
pos_l = pos_frame(1) + pos_frame(3) - 6 - pos_w;
%pos_t = pos_frame(2) + 6;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb ShowWhite', ...
  'Interruptible', 'off', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','提取主分量', ...
  'FontSize',12,...
  'Tag','b_ShowWhite');

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Controls in f_ica
pos_frame=get(h_f_ica, 'Position');
pos_l = pos_frame(1) + 6;
pos_h = 20;
pos_t = pos_frame(2) + pos_frame(4) - pos_h - 6;
pos_w = 150;
b = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','盲源分离算法:', ...
  'FontSize',12,...
  'Style','text', ...
  'Tag','t_white');

pos_l = pos_l + pos_w;
pos_w = 180;
ht_FastICA_icaStatus = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l-10 pos_t pos_w pos_h], ...
  'String','请选择算法', ...
  'FontSize',12,...
  'Style','text', ...
  'Tag','t_icaStatus');

% V鋒鋘 v鋖i?pos_t = pos_t - 8;

%pos_l = pos_frame(1) + 6;
pos_l = pos_frame(1) + 6 + 150;
pos_t = pos_t - pos_h;
%pos_w = 260;
pos_w = 120;
b = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Approach:', ...
  'Style','text', ...
  'visible','off',...
  'Tag','t_5');

pos_w = 100;
%pos_t = pos_t - 4;
pos_l = pos_frame(1) + pos_frame(3) - 6 - pos_w;
hpm_FastICA_approach = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'Callback','gui_cb ChangeApproach', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String',c_FastICA_appr_strD, ...
  'Style','popupmenu', ...
  'visible','off',...
  'Tag','pm_approach', ...
  'Value',g_FastICA_approach);

%pos_t = pos_t - 4;
%pos_l = pos_frame(1) + 6;
pos_l = pos_frame(1) + 6 + 150;
pos_t = pos_t - pos_h;
%pos_w = 260;
pos_w = 120;
b = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Number of ICs:', ...
  'Style','text', ...
  'visible','off',...
  'Tag','t_6');

pos_w = 100;
pos_l = pos_frame(1) + pos_frame(3) - 6 - pos_w;
he_FastICA_numOfIC = uicontrol('Parent',a, ...
  'BackgroundColor',[1 1 1], ...
  'Callback','gui_cb ChangeNumOfIC', ...
  'HorizontalAlignment','right', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','0', ...
  'Style','edit', ...
  'visible','off',...
  'Tag','e_numOfIC');

%pos_t = pos_t - 4;
%pos_l = pos_frame(1) + 6;
pos_l = pos_frame(1) + 6 + 150;
pos_t = pos_t - pos_h;
%pos_w = 260;
pos_w = 120;
b = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Nonlinearity (g):', ...
  'Style','text', ...
  'visible','off',...
  'Tag','t_71');

%pos_t = pos_t - 4;
pos_w = 100;
pos_l = pos_frame(1) + pos_frame(3) - 6 - pos_w;
hpm_FastICA_g = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'Callback','gui_cb ChangeG', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String',c_FastICA_g1_strD, ...
  'Style','popupmenu', ...
  'visible','off',...
  'Tag','pm_g', ...
  'Value',g_FastICA_g);

%pos_t = pos_t - 4;
%pos_l = pos_frame(1) + 6;
pos_l = pos_frame(1) + 6 + 150;
pos_t = pos_t - pos_h;
%pos_w = 260;
pos_w = 120;
b = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'HorizontalAlignment','left', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Stabilization:', ...
  'Style','text', ...
  'visible','off',...
  'Tag','t_71a');

%pos_t = pos_t - 4;
pos_w = 100;
pos_l = pos_frame(1) + pos_frame(3) - 6 - pos_w;
hpm_FastICA_stabilization = uicontrol('Parent',a, ...
  'BackgroundColor',bgc, ...
  'Callback','gui_cb ChangeStab', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String',c_FastICA_stabili_strD, ...
  'Style','popupmenu', ...
  'visible','off',...
  'Tag','pm_stab', ...
  'Value',g_FastICA_stabilization);



pos_l = pos_frame(1) + pos_vspace;
pos_w = 110;
pos_h = 30;
pos_t = pos_frame(2) + pos_hspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb AdvOpt', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Adv. options >>', ...
  'visible','off',...
  'Tag','b_advOpt');

pos_w = 130;
pos_h = 30;
pos_l = pos_frame(1) + pos_frame(3) - pos_vspace - pos_w;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb ShowICASig', ...
  'Interruptible', 'on', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Plot ICs', ...
  'visible','off',...
  'Tag','b_ShowICASig');





h = uibuttongroup('Parent',a,...
    'visible','off','Position',[0 0 .2 1]);

u1 = uicontrol('Style','Radio','String','Fast_ICA',...
    'pos',[10 100 90 30],'parent',h,'HandleVisibility','off');
u2 = uicontrol('Style','Radio','String','jada_ICA',...
    'pos',[10 60 90 30],'parent',h,'HandleVisibility','off');
u3 = uicontrol('Style','Radio','String','ogwe_ICA',...
    'pos',[10 20 90 30],'parent',h,'HandleVisibility','off');

u4 = uicontrol('Style','Radio','String','Pearson_ICA',...
    'pos',[110 100 90 30],'parent',h,'HandleVisibility','off');
u5 = uicontrol('Style','Radio','String','shibbs_ICA',...
    'pos',[110 60 90 30],'parent',h,'HandleVisibility','off');
u6 = uicontrol('Style','Radio','String','EGLD_ICA',...
    'pos',[110 20 90 30],'parent',h,'HandleVisibility','off');

u7 = uicontrol('Style','Radio','String','自然梯度','FontSize',10,...
    'pos',[210 100 80 30],'parent',h,'HandleVisibility','off');
u8 = uicontrol('Style','Radio','String','全局最优','FontSize',10,...
    'pos',[210 60 80 30],'parent',h,'HandleVisibility','off');
u9 = uicontrol('Style','Radio','String','长短滤波','FontSize',10,...
    'pos',[210 20 80 30],'parent',h,'HandleVisibility','off');

u10 = uicontrol('Style','Radio','String','最大信噪比','FontSize',10,...
    'pos',[300 100 90 30],'parent',h,'HandleVisibility','off');
u11 = uicontrol('Style','Radio','String','改进开关法','FontSize',10,...
    'pos',[300 60 90 30],'parent',h,'HandleVisibility','off');
u12 = uicontrol('Style','Radio','String','去相关算法','FontSize',10,...
    'pos',[300 20 90 30],'parent',h,'HandleVisibility','off');

set(h,'SelectionChangeFcn',@selcbk);
set(h,'SelectedObject',[]);  % No selection
set(h,'Visible','on');
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Controls in f_side
pos_vspace = 6;
pos_hspace = 10;
pos_temp=get(h_f_side, 'Position');
pos_l=pos_temp(1)+pos_hspace;
pos_w=100;
pos_h=30;
pos_t=pos_temp(2)+pos_temp(4)-pos_vspace-pos_h;

b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb LoadData', ...
  'Interruptible', 'off', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','加载数据', ...
  'FontSize',12,...
  'Tag','b_LoadData');


pos_t=pos_t-pos_h-pos_vspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb DoFPICA', ...
  'Interruptible', 'on', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','盲分离', ...
  'FontSize',12,...
  'Tag','b_DoFPICA');

pos_t=pos_t-pos_h-pos_vspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb SaveData', ...
  'Interruptible', 'off', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','保存结果', ...
  'FontSize',12,...
  'Tag','b_SaveData');
%增加的按钮
pos_t=pos_t-pos_h-pos_vspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb MixData', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','数据代码', ...
  'FontSize',12,...
  'Tag','b_mixdata');
%***********************************
pos_t=pos_t-pos_h-pos_vspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb Quit', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','退  出', ...
  'FontSize',12,...
  'Tag','b_Quit');

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
pos_t=pos_t-pos_h-pos_vspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb Interrupt', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Interrupt', ...
  'Visible','off', ...
  'Tag','b_Interrupt');

pos_t = pos_frame(2) + pos_vspace + pos_h + pos_vspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb About', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','About...', ...
  'Tag','b_About');

pos_t = pos_frame(2) + pos_vspace;
b = uicontrol('Parent',a, ...
  'BackgroundColor',[0.701961 0.701961 0.701961], ...
  'Callback','gui_cb Help', ...
  'Position',[pos_l pos_t pos_w pos_h], ...
  'String','Help', ...
  'Tag','b_Help');

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Do rest of the initialization...
  gui_cb InitAll;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -