Correlation Coefficient between multiple table columns
47 views (last 30 days)
Show older comments
I have 3 tables all which are 365x6. I want to find the correlation coefficient of table 1 column 1 against the remaining 5 columns of table 1 and all columns of table 2 and 3.
Thanks in advance
0 Comments
Answers (1)
dpb
on 23 Mar 2019
Try
doc corrcoef % see examples re: NaN
When you're still learning way around Matlab, a very useful (albeit old and pretty-much ignored by TMW any more) tool is lookfor --
>> lookfor correlation
corrcoef - Correlation coefficients.
ac2poly - Convert autocorrelation sequence to prediction polynomial.
ac2rc - Convert autocorrelation sequence to reflection coefficients.
corrmtx - Autocorrelation matrix.
poly2ac - Convert prediction polynomial to autocorrelation sequence.
rc2ac - reflection coefficients to autocorrelation sequence.
xcorr - Cross-correlation function estimates.
xcorr2 - Two-dimensional cross-correlation.
canoncorr - Canonical correlation analysis.
cophenet - Cophenetic correlation coefficient.
copulaparam - Copula parameters as a function of rank correlation.
copulastat - Rank correlation for a copula.
corr - Linear or rank correlation.
corrcov - Compute correlation matrix from covariance matrix.
dwtest - Durbin-Watson test for autocorrelation in linear regression.
partialcorr - Linear or rank partial correlation coefficients.
partialcorri - Partial correlation coefficients with internal adjustments.
>>
A keyword or guess at one will provide a list from which you can see what may be of interest...in your case, it turns out #1 on the list...or, of course, use the graphic tools and search in the documentation browser but it isn't nearly so succinct.
1 Comment
Peter Perkins
on 25 Mar 2019
Or lucky #13: corr. That requires the Statists and Machine Learning Toolbox.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!