title: Pearson and Spearman correlation and the corresponding 95% and 99% confidence level in Matlab
body: <p>if I have two series of data:
  <code>a = [1 4 6 3 4 6 7 8];</code> 
  <code>b [34 56 34 56 79 23 48 28];</code> Then i can find the spearman and pearson correlation coefficient respectively as: 
  <code>RHO= corr(a',b','Type','Spearman');</code> 
  for pearson correlation, i can use:
  <code>r=corr2(a,b)</code>
    or </p>
  
  <pre><code>[R] = corr(a',b','Type','pearson')
  </code></pre>
  
  <p>what will be the confidence level (95% and 99%) both for pearson and spearman correlation. i need result as in the given example.
  let,</p>
  
  <pre><code>pearson correlation r=0.76
  
  spearman rank correlation r=0.65
  
  95% confidence level=0.34
  
  99% confidence level=0.42
  </code></pre>
  
  <p>Note: My values of correlation coefficients and confidence level are general, they are not for given 'a' and 'b' values above.
  thanks.</p>