ProcessPCA
带有主成分分析的矩阵的过程列
句法
[Y,PS] = ProcessPCA(X,MaxFrac)
[Y,PS] = ProcessPCA(X,FP)
y = processPCA('apply',x,ps)
x = processpca('反向',y,ps)
名称= processPCA('name')
fp = processPCA('pdefaults')
名称= ProcessPCA('PDESC')
ProcessPCA('pCheck',fp);
描述
ProcessPCA
使用主成分分析过程矩阵sis so that each row is uncorrelated, the rows are in the order of the amount they contribute to total variation, and rows whose contribution to total variation are less thanMAXFRAC
被删除。
[Y,PS] = ProcessPCA(X,MaxFrac)
带X
and an optional parameter,
X |
|
MAXFRAC |
删除行的最大差异分数(默认为0) |
并返回
y |
|
PS |
流程设置可以允许价值的一致处理 |
[Y,PS] = ProcessPCA(X,FP)
带parameters as a struct:fp.maxfrac
。
y = processPCA('apply',x,ps)
返回y
,给予X
和设置PS
。
x = processpca('反向',y,ps)
返回X
,给予y
和设置PS
。
名称= processPCA('name')
返回此过程方法的名称。
fp = processPCA('pdefaults')
返回default process parameter structure.
名称= ProcessPCA('PDESC')
返回过程参数描述。
ProcessPCA('pCheck',fp);
如果任何参数是非法的,则会引发错误。
例子
Here is how to format a matrix with an independent row, a correlated row, and a completely redundant row so that its rows are uncorrelated and the redundant row is dropped.
x1_independent = rand(1,5)x1_correalated = rand(1,5) + x1_indepentent;x1_redeartion = x1_independent + x1_correcated x1 = [x1_independent;x1_corlyated;x1_redeend] [y1,ps] = ProcessPCA(x1)
接下来,将相同的处理设置应用于新值。
x2_indepentent = rand(1,5)x2_correalated = rand(1,5) + x1_indepentent;x2_redeartion = x1_independent + x1_correcated x2 = [x2_independent;x2_corlyated;x2_redlext];Y2 = ProcessPCA('Apply',X2,PS)
Reverse the processing ofY1
要得到x1
again.
X1_AGAIN = ProcessPCA('reververs',Y1,PS)
更多关于
算法
元素不全部相同值的行中的值设置为
y = 2*(x-minx)/(maxx-minx)-1;
所有相同值的行中的值设置为0。