How to calculate the correlation between 4 variables in a matrix

13 visualizaciones (últimos 30 días)
Tushar Agarwal
Tushar Agarwal el 27 de Oct. de 2016
Respondida: Jos (10584) el 27 de Oct. de 2016
Hello, I have a matrix with 4 variables. I want to find out the correlation of each variable with one another - so I used corr function.
But i want to know, if while doing so, it takes into account the effect of other variables too - example, if correlation of cols 1 and 2 is being calculated, does it take into account the effects of col 3 and 4 as well? I am in need for a correlation of col 1 with all other cols, and so on for each col vs all other cols.

Respuestas (1)

Jos (10584)
Jos (10584) el 27 de Oct. de 2016
See the documentation on CORR and PARTIALCORR, both in the Statistics Toolbox:

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by