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

📄 da_pcavr.m

📁 王小平《遗传算法——理论、应用与软件实现》随书光盘
💻 M
字号:
%
% da_pcavr
%
% Plots the variance of the individual prinipal
% components
%

w1=gcf;
da_front;
da_pcapb;
set(w1,'NumberTitle','off','Name','Principal Component Analysis');
drawnow;

figure(w1);
ax1=axes(...
	'Units','pixels',...
	'Position',[80 120 500 270],...
	'Box','on',...
	'Color',[0 0 0],...
	'Visible','on');

%
% Print a title
%
text1=da_text(w1,200,410,250,15,'Plot of principal component variances',[1 1 1],[1 0 0]);
%
% Plot the contribution to a model plot
%
%bar(ssq(:,4));
%
% Own PCA routine
%
bar(ssq);

[D L]=size(ssq);
set(ax1,'Xlim',[0 D],'Ylim',[0 100]);
Xlabel('Principal component number');
Ylabel('Percentage variation in original data explained');


%
% Save coefficients button
%
but10=uicontrol(w1,...
	'style','push',...
	'position',[20 40 175 20],...
	'string','Save loadings',...
	'callback',[
		'dummy=pcincl(data,include_var,output_var);',...
		'[dummy m s]=mcen(dummy);',...
		'clear dummy;',...
		'svpca('''',include_var,m,s,c);']);

⌨️ 快捷键说明

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