亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? pcamat.m

?? fastica法的matlab工具包
?? M
字號:
function [E, D] = pcamat(vectors, firstEig, lastEig, s_interactive, ...    s_verbose);%PCAMAT - Calculates the pca for data%% [E, D] = pcamat(vectors, firstEig, lastEig, ... %                 interactive, verbose);%% Calculates the PCA matrices for given data (row) vectors. Returns% the eigenvector (E) and diagonal eigenvalue (D) matrices containing the% selected subspaces. Dimensionality reduction is controlled with% the parameters 'firstEig' and 'lastEig' - but it can also be done% interactively by setting parameter 'interactive' to 'on' or 'gui'.%% ARGUMENTS%% vectors       Data in row vectors.% firstEig      Index of the largest eigenvalue to keep.%               Default is 1.% lastEig       Index of the smallest eigenvalue to keep.%               Default is equal to dimension of vectors.% interactive   Specify eigenvalues to keep interactively. Note that if%               you set 'interactive' to 'on' or 'gui' then the values%               for 'firstEig' and 'lastEig' will be ignored, but they%               still have to be entered. If the value is 'gui' then the%               same graphical user interface as in FASTICAG will be%               used. Default is 'off'.% verbose       Default is 'on'.%%% EXAMPLE%       [E, D] = pcamat(vectors);%% Note %       The eigenvalues and eigenvectors returned by PCAMAT are not sorted.%% This function is needed by FASTICA and FASTICAG% For historical reasons this version does not sort the eigenvalues or% the eigen vectors in any ways. Therefore neither does the FASTICA or% FASTICAG. Generally it seams that the components returned from% whitening is almost in reversed order. (That means, they usually are,% but sometime they are not - depends on the EIG-command of matlab.)% @(#)$Id: pcamat.m,v 1.5 2003/12/15 18:24:32 jarmo Exp $%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Default values:if nargin < 5, s_verbose = 'on'; endif nargin < 4, s_interactive = 'off'; endif nargin < 3, lastEig = size(vectors, 1); endif nargin < 2, firstEig = 1; end%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Check the optional parameters;switch lower(s_verbose) case 'on'  b_verbose = 1; case 'off'  b_verbose = 0; otherwise  error(sprintf('Illegal value [ %s ] for parameter: ''verbose''\n', s_verbose));endswitch lower(s_interactive) case 'on'  b_interactive = 1; case 'off'  b_interactive = 0; case 'gui'  b_interactive = 2; otherwise  error(sprintf('Illegal value [ %s ] for parameter: ''interactive''\n', ...		s_interactive));endoldDimension = size (vectors, 1);if ~(b_interactive)  if lastEig < 1 | lastEig > oldDimension    error(sprintf('Illegal value [ %d ] for parameter: ''lastEig''\n', lastEig));  end  if firstEig < 1 | firstEig > lastEig    error(sprintf('Illegal value [ %d ] for parameter: ''firstEig''\n', firstEig));  endend%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Calculate PCA% Calculate the covariance matrix.if b_verbose, fprintf ('Calculating covariance...\n'); endcovarianceMatrix = cov(vectors', 1);% Calculate the eigenvalues and eigenvectors of covariance% matrix.[E, D] = eig (covarianceMatrix);% The rank is determined from the eigenvalues - and not directly by% using the function rank - because function rank uses svd, which% in some cases gives a higher dimensionality than what can be used% with eig later on (eig then gives negative eigenvalues).rankTolerance = 1e-7;maxLastEig = sum (diag (D) > rankTolerance);if maxLastEig == 0,  fprintf (['Eigenvalues of the covariance matrix are' ...	    ' all smaller than tolerance [ %g ].\n' ...	    'Please make sure that your data matrix contains' ...	    ' nonzero values.\nIf the values are very small,' ...	    ' try rescaling the data matrix.\n'], rankTolerance);  error ('Unable to continue, aborting.');end% Sort the eigenvalues - decending.eigenvalues = flipud(sort(diag(D)));%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Interactive part - command-lineif b_interactive == 1  % Show the eigenvalues to the user  hndl_win=figure;  bar(eigenvalues);  title('Eigenvalues');  % ask the range from the user...  % ... and keep on asking until the range is valid :-)  areValuesOK=0;  while areValuesOK == 0    firstEig = input('The index of the largest eigenvalue to keep? (1) ');    lastEig = input(['The index of the smallest eigenvalue to keep? (' ...                    int2str(oldDimension) ') ']);    % Check the new values...    % if they are empty then use default values    if isempty(firstEig), firstEig = 1;end    if isempty(lastEig), lastEig = oldDimension;end    % Check that the entered values are within the range    areValuesOK = 1;    if lastEig < 1 | lastEig > oldDimension      fprintf('Illegal number for the last eigenvalue.\n');      areValuesOK = 0;    end    if firstEig < 1 | firstEig > lastEig      fprintf('Illegal number for the first eigenvalue.\n');      areValuesOK = 0;    end  end  % close the window  close(hndl_win);end%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Interactive part - GUIif b_interactive == 2  % Show the eigenvalues to the user  hndl_win = figure('Color',[0.8 0.8 0.8], ...    'PaperType','a4letter', ...    'Units', 'normalized', ...    'Name', 'FastICA: Reduce dimension', ...    'NumberTitle','off', ...    'Tag', 'f_eig');  h_frame = uicontrol('Parent', hndl_win, ...    'BackgroundColor',[0.701961 0.701961 0.701961], ...    'Units', 'normalized', ...    'Position',[0.13 0.05 0.775 0.17], ...    'Style','frame', ...    'Tag','f_frame');b = uicontrol('Parent',hndl_win, ...	'Units','normalized', ...	'BackgroundColor',[0.701961 0.701961 0.701961], ...	'HorizontalAlignment','left', ...	'Position',[0.142415 0.0949436 0.712077 0.108507], ...	'String','Give the indices of the largest and smallest eigenvalues of the covariance matrix to be included in the reduced data.', ...	'Style','text', ...	'Tag','StaticText1');e_first = uicontrol('Parent',hndl_win, ...	'Units','normalized', ...	'Callback',[ ...          'f=round(str2num(get(gcbo, ''String'')));' ...          'if (f < 1), f=1; end;' ...          'l=str2num(get(findobj(''Tag'',''e_last''), ''String''));' ...          'if (f > l), f=l; end;' ...          'set(gcbo, ''String'', int2str(f));' ...          ], ...	'BackgroundColor',[1 1 1], ...	'HorizontalAlignment','right', ...	'Position',[0.284831 0.0678168 0.12207 0.0542535], ...	'Style','edit', ...        'String', '1', ...	'Tag','e_first');b = uicontrol('Parent',hndl_win, ...	'Units','normalized', ...	'BackgroundColor',[0.701961 0.701961 0.701961], ...	'HorizontalAlignment','left', ...	'Position',[0.142415 0.0678168 0.12207 0.0542535], ...	'String','Range from', ...	'Style','text', ...	'Tag','StaticText2');e_last = uicontrol('Parent',hndl_win, ...	'Units','normalized', ...	'Callback',[ ...          'l=round(str2num(get(gcbo, ''String'')));' ...          'lmax = get(gcbo, ''UserData'');' ...          'if (l > lmax), l=lmax; fprintf([''The selected value was too large, or the selected eigenvalues were close to zero\n'']); end;' ...          'f=str2num(get(findobj(''Tag'',''e_first''), ''String''));' ...          'if (l < f), l=f; end;' ...          'set(gcbo, ''String'', int2str(l));' ...          ], ...	'BackgroundColor',[1 1 1], ...	'HorizontalAlignment','right', ...	'Position',[0.467936 0.0678168 0.12207 0.0542535], ...	'Style','edit', ...        'String', int2str(maxLastEig), ...        'UserData', maxLastEig, ...	'Tag','e_last');% in the first version oldDimension was used instead of % maxLastEig, but since the program would automatically% drop the eigenvalues afte maxLastEig...b = uicontrol('Parent',hndl_win, ...	'Units','normalized', ...	'BackgroundColor',[0.701961 0.701961 0.701961], ...	'HorizontalAlignment','left', ...	'Position',[0.427246 0.0678168 0.0406901 0.0542535], ...	'String','to', ...	'Style','text', ...	'Tag','StaticText3');b = uicontrol('Parent',hndl_win, ...	'Units','normalized', ...	'Callback','uiresume(gcbf)', ...	'Position',[0.630697 0.0678168 0.12207 0.0542535], ...	'String','OK', ...	'Tag','Pushbutton1');b = uicontrol('Parent',hndl_win, ...	'Units','normalized', ...	'Callback',[ ...          'gui_help(''pcamat'');' ...          ], ...	'Position',[0.767008 0.0678168 0.12207 0.0542535], ...	'String','Help', ...	'Tag','Pushbutton2');  h_axes = axes('Position' ,[0.13 0.3 0.775 0.6]);  set(hndl_win, 'currentaxes',h_axes);  bar(eigenvalues);  title('Eigenvalues');  uiwait(hndl_win);  firstEig = str2num(get(e_first, 'String'));  lastEig = str2num(get(e_last, 'String'));  % close the window  close(hndl_win);end%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% See if the user has reduced the dimension enoughtif lastEig > maxLastEig  lastEig = maxLastEig;  if b_verbose    fprintf('Dimension reduced to %d due to the singularity of covariance matrix\n',...           lastEig-firstEig+1);  endelse  % Reduce the dimensionality of the problem.  if b_verbose    if oldDimension == (lastEig - firstEig + 1)      fprintf ('Dimension not reduced.\n');    else      fprintf ('Reducing dimension...\n');    end  endend%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Drop the smaller eigenvaluesif lastEig < oldDimension  lowerLimitValue = (eigenvalues(lastEig) + eigenvalues(lastEig + 1)) / 2;else  lowerLimitValue = eigenvalues(oldDimension) - 1;endlowerColumns = diag(D) > lowerLimitValue;%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Drop the larger eigenvaluesif firstEig > 1  higherLimitValue = (eigenvalues(firstEig - 1) + eigenvalues(firstEig)) / 2;else  higherLimitValue = eigenvalues(1) + 1;endhigherColumns = diag(D) < higherLimitValue;% Combine the results from aboveselectedColumns = lowerColumns & higherColumns;%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% print some info for the userif b_verbose  fprintf ('Selected [ %d ] dimensions.\n', sum (selectedColumns));endif sum (selectedColumns) ~= (lastEig - firstEig + 1),  error ('Selected a wrong number of dimensions.');endif b_verbose  fprintf ('Smallest remaining (non-zero) eigenvalue [ %g ]\n', eigenvalues(lastEig));  fprintf ('Largest remaining (non-zero) eigenvalue [ %g ]\n', eigenvalues(firstEig));  fprintf ('Sum of removed eigenvalues [ %g ]\n', sum(diag(D) .* ...    (~selectedColumns)));end%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Select the colums which correspond to the desired range% of eigenvalues.E = selcol(E, selectedColumns);D = selcol(selcol(D, selectedColumns)', selectedColumns);%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Some more informationif b_verbose  sumAll=sum(eigenvalues);  sumUsed=sum(diag(D));  retained = (sumUsed / sumAll) * 100;  fprintf('[ %g ] %% of (non-zero) eigenvalues retained.\n', retained);end%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%function newMatrix = selcol(oldMatrix, maskVector);% newMatrix = selcol(oldMatrix, maskVector);%% Selects the columns of the matrix that marked by one in the given vector.% The maskVector is a column vector.% 15.3.1998if size(maskVector, 1) ~= size(oldMatrix, 2),  error ('The mask vector and matrix are of uncompatible size.');endnumTaken = 0;for i = 1 : size (maskVector, 1),  if maskVector(i, 1) == 1,    takingMask(1, numTaken + 1) = i;    numTaken = numTaken + 1;  endendnewMatrix = oldMatrix(:, takingMask);

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品私人自拍| 色婷婷av久久久久久久| 国产在线乱码一区二区三区| 免费观看一级特黄欧美大片| 国产黄色精品网站| 91久久精品网| 国产日韩三级在线| 日韩专区中文字幕一区二区| 国产不卡在线一区| 日韩免费性生活视频播放| 国产精品久久久久久亚洲毛片 | 亚洲国产精品一区二区久久| 国产乱淫av一区二区三区 | 777久久久精品| 国产精品不卡一区| 欧美军同video69gay| 国产精品久久看| 欧美日韩1234| 亚洲一区自拍偷拍| av男人天堂一区| 久久久久99精品一区| 五月天网站亚洲| 欧美伦理电影网| 国产精品1024久久| 一级女性全黄久久生活片免费| 成人黄色大片在线观看| 欧美高清在线视频| 岛国一区二区在线观看| 欧美国产精品v| 欧美精品第1页| 国产99久久久国产精品免费看 | 激情六月婷婷综合| 亚洲欧美日韩国产另类专区| 国产精品综合一区二区三区| 一个色妞综合视频在线观看| 精品99久久久久久| 精品无人码麻豆乱码1区2区| 久久综合久久99| 国产盗摄一区二区三区| 亚洲chinese男男1069| 日韩一区二区免费视频| 久久精品国产在热久久| 久久综合色之久久综合| 欧美无砖砖区免费| 爽好多水快深点欧美视频| 中文字幕精品一区| 2023国产精华国产精品| 欧美丰满少妇xxxxx高潮对白| 91视频观看免费| 亚洲国产精品久久久久婷婷884 | 青青青爽久久午夜综合久久午夜| 国产精品国产自产拍高清av王其 | 日韩美女精品在线| 欧美性做爰猛烈叫床潮| 成人美女在线观看| 国产在线视频一区二区三区| 青青国产91久久久久久| 亚洲午夜三级在线| 久久99国产乱子伦精品免费| 972aa.com艺术欧美| 一区二区三区四区亚洲| 日本一区二区视频在线| 在线观看亚洲精品| 精品一区二区久久久| 丝袜脚交一区二区| 亚洲成人在线网站| 亚洲国产一区二区三区青草影视| 亚洲欧洲色图综合| 日韩欧美电影一区| 日韩欧美在线一区二区三区| 666欧美在线视频| 欧美视频中文字幕| 欧美综合亚洲图片综合区| 91网站最新网址| 成人av中文字幕| 大桥未久av一区二区三区中文| 国内精品久久久久影院薰衣草| 激情小说亚洲一区| 国产一区二区三区在线看麻豆| 中文字幕国产精品一区二区| 欧美激情一区不卡| 国产精品福利一区| 国产福利一区在线| 成人性生交大片免费看在线播放| 国产成人精品aa毛片| 北条麻妃一区二区三区| 97se亚洲国产综合自在线不卡| 一本色道久久综合亚洲精品按摩| 色婷婷综合激情| 在线电影一区二区三区| 精品国产123| 国产精品久久久99| 亚洲国产美女搞黄色| 日本在线不卡一区| 中文字幕一区二区三区不卡在线 | 99国产精品国产精品毛片| 91免费观看在线| 欧美人动与zoxxxx乱| 久久在线免费观看| 最近中文字幕一区二区三区| 亚洲一区二区三区四区五区中文| 日本成人超碰在线观看| 国产成人精品三级| 欧美在线不卡视频| 精品国产乱码久久久久久牛牛| 国产欧美日本一区视频| 亚洲最大成人综合| 久久66热re国产| www.欧美亚洲| 91精品在线免费| 国产精品久久久久久久久免费樱桃| 一区二区三区在线视频播放| 精品综合免费视频观看| 91丨porny丨蝌蚪视频| 日韩一级精品视频在线观看| 国产精品麻豆网站| 免费av成人在线| 91女人视频在线观看| 日韩欧美国产综合在线一区二区三区| 国产欧美日韩精品一区| 五月婷婷综合网| 97久久人人超碰| 久久综合狠狠综合久久综合88| 一区二区在线观看免费视频播放| 亚洲欧美色图小说| 久久精品国产亚洲5555| 91免费在线播放| 欧美精品一区二区久久久| 一区二区三区不卡视频| 成人白浆超碰人人人人| 日韩三级电影网址| 亚洲成a人片在线不卡一二三区 | 99国内精品久久| 欧美xxxx老人做受| 精品久久99ma| 一区二区三区四区蜜桃| 国产成人免费在线观看不卡| 这里只有精品99re| 一区二区三区中文字幕电影| 国产乱淫av一区二区三区| 欧美精品久久99久久在免费线| 亚洲欧洲国产专区| 国产精品69久久久久水密桃| 日韩欧美中文字幕精品| 香蕉成人啪国产精品视频综合网| 91麻豆6部合集magnet| 中文字幕国产一区二区| 欧美一级生活片| 久久亚洲欧美国产精品乐播 | 色成年激情久久综合| 国产女同互慰高潮91漫画| 美女视频黄 久久| 成人激情电影免费在线观看| 精品精品国产高清一毛片一天堂| 日韩av高清在线观看| 欧美在线一二三| 有码一区二区三区| 在线看日本不卡| 洋洋av久久久久久久一区| 在线亚洲人成电影网站色www| 国产精品动漫网站| 不卡的看片网站| 亚洲欧洲国产日韩| 一本久道中文字幕精品亚洲嫩| 欧美极品aⅴ影院| 粉嫩av一区二区三区| 国产精品无圣光一区二区| 成人影视亚洲图片在线| 中文字幕第一区二区| av日韩在线网站| 亚洲精品免费在线| 欧美日韩中文字幕一区| 久久久久久久久蜜桃| 国产精品原创巨作av| 欧美国产日韩亚洲一区| 成人福利视频网站| 亚洲欧美另类综合偷拍| 欧美在线|欧美| 日本va欧美va精品| 欧美成人性战久久| 国产精品香蕉一区二区三区| 国产精品视频线看| 91麻豆视频网站| 亚洲国产人成综合网站| 欧美一级高清片| 国产美女久久久久| 成人欧美一区二区三区1314| 色94色欧美sute亚洲线路一久| 亚洲小说春色综合另类电影| 欧美一级一区二区| 精品播放一区二区| 福利电影一区二区| 亚洲精品乱码久久久久久日本蜜臀| 欧美无人高清视频在线观看| 日本亚洲三级在线| 国产精品乱码一区二三区小蝌蚪| 色婷婷一区二区| 蜜桃av一区二区在线观看| 欧美激情一区在线| 欧美日韩国产免费一区二区|