 
Pearson's correlation coefficient  using R
Pearson's correlation coefficient
It is simple enough to calculate Pearson's correlation coefficient, from first principles, if you only need its value.

Gave us this:
Test of Pearson's correlation coefficient

Which produced the result shown below:
Notice that, since method="pearson" is the default for this function, we have only included for sake of clarity.
Pearson's productmoment correlation
data: x and y
t = 2.9012, df = 16, pvalue = 0.01042
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.1656595 0.8272375
sample estimates:
cor
0.5871208


We now repeat the test without the influential (deviant ??) point to assess how robust the result is:
Pearson's correlation coefficient

The R output for the Pearson correlation test is as follows:
Pearson's productmoment correlation
data: x and y
t = 2.2368, df = 15, pvalue = 0.04091
alternative hypothesis: true correlation is not equal to 0
95 percent confidence interval:
0.0256361 0.7906962
sample estimates:
cor
0.5001185


