?? klms.m
字號(hào):
%KLMS Karhunen Loeve Mapping, followed by scaling% % [W,FRAC] = KLMS(A,N)% [W,N] = KLMS(A,FRAC)% % INPUT% A Dataset% N or FRAC Number of dimensions (>= 1) or fraction of variance (< 1) % to retain; if > 0, perform PCA; otherwise MCA. Default: N = inf.%% OUTPUT% W Affine Karhunen-Loeve mapping% FRAC or N Fraction of variance or number of dimensions retained.%% DESCRIPTION% First a Karhunen Loeve Mapping is performed (i.e. PCA or MCA on the average % prior-weighted class covariance matrix). The result is scaled by the mean % class standard deviations. For N and FRAC, see KLM.%% Default N: select all ('pre-whiten' the average covariance matrix, i.e.% orthogonalize and scale). The resulting mapping has a unit average% covariance matrix.% % SEE ALSO% MAPPINGS, DATASETS, KLM, PCA% Copyright: R.P.W. Duin, duin@ph.tn.tudelft.nl% Faculty of Applied Physics, Delft University of Technology% P.O. Box 5046, 2600 GA Delft, The Netherlands% $Id: klms.m,v 1.5 2003/10/07 11:58:37 bob Exp $function [w,truefrac] = klms(a,n) prtrace(mfilename); if (nargin < 2), n = []; end; if (nargin < 1) | (isempty(a)) w = mapping('klms',n); w = setname(w,'Scaled KL Mapping'); return end [w,truefrac] = klm(a,n); % Calculate KL mapping b = a*w; % Combine KL mapping with scaling on w = w*scalem(b,'c-variance'); % KL-mapped data w = setname(w,'Scaled KL Mapping'); return
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -