pearson and Spearman correlation and the corresponding 95% and 99% confidence level in Matlab
Show older comments
Hey Matlab users, i have copied a question asked in mathworks. i understand the answer of this question but i want how to find the corresponding 95% and 99% confidence level for both the pearson and spearman correlation coefficient. if I have two series of data:
a = [1 4 6 3 4 6 7 8]; b [34 56 34 56 79 23 48 28]; Then i can find the spearman and pearson correlation coefficient respectively as:
[RHO,PVAL] = corr(a',b','Type','Spearman'); for pearson, i can use r=corr2(a,b) or [R] = corr(a',b','Type','pearson') what will be the confidence leve(95% and 99%).i need result like in the given figure.the correlation result in fig is not related to the values of 'a' and 'b'.

Thanks for your help.
Accepted Answer
More Answers (1)
Mehri Mehrnia
on 21 May 2023
0 votes
Is "corrcoef" for Spearman correlation?
Categories
Find more on Correlation and Convolution in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!