matlab 求 相关系数

来源:学生作业帮助网 编辑:六六作业网 时间:2024/12/22 16:39:37
matlab求相关系数matlab求相关系数matlab求相关系数SyntaxR=corrcoef(X)R=corrcoef(x,y)[R,P]=corrcoef(...)[R,P,RLO,RUP]=

matlab 求 相关系数
matlab 求 相关系数

matlab 求 相关系数
Syntax
R = corrcoef(X)
R = corrcoef(x,y)
[R,P]=corrcoef(...)
[R,P,RLO,RUP]=corrcoef(...)
[...]=corrcoef(...,'param1',val1,'param2',val2,...)
Description
R = corrcoef(X) returns a matrix R of correlation coefficients calculated from an input matrix X whose rows are observations and whose columns are variables.
Examples
Generate random data having correlation between column 4 and the other columns.x = randn(30,4); % Uncorrelated data
x(:,4) = sum(x,2); % Introduce correlation.
[r,p] = corrcoef(x) % Compute sample correlation and p-values.
[i,j] = find(p