Calculating correlation matrix from time series in an array
조회 수: 8 (최근 30일)
이전 댓글 표시
I have a cell array with 164 entities, each with an entry of 193X1 time points. I need to create a correlation matrix of the dimension 164X164 with pearson correlations. How can I go about doing that?
댓글 수: 0
답변 (1개)
Ameer Hamza
2020년 9월 21일
편집: Ameer Hamza
2020년 9월 21일
Use corrcoef() but first convert the matrix to correct form
C = % 164 elements cell array
Cv = [C{:}]; % creating a matrix
coff_matrix = corrcoef(Cv); % 164x164 matrix
댓글 수: 4
Ameer Hamza
2020년 9월 21일
Without more information about the content of each mat file (i.e., names of variables) and how they are stored, it is difficult to give an exact solution.
참고 항목
카테고리
Help Center 및 File Exchange에서 Matrices and Arrays에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!