Home > Statistical Methods calculators > Pearson's Correlation Coefficient example

1. Pearson's Correlation Coefficient example ( Enter your problem )
  1. Formula & Example-1 (Class-X & Y)
  2. Example-2 (Class-X & Y)
  3. Example-3 (X & Y)
  4. Example-4 (X & Y)
Other related methods
  1. Correlation Coefficient r
  2. Covariance - Population Covariance, Sample Covariance

2. Example-2 (Class-X & Y)
(Previous example)
4. Example-4 (X & Y)
(Next example)

3. Example-3 (X & Y)





Formula
1. `r = (n * sum xy - sum x * sum y)/(sqrt(n * sum x^2 - (sum x)^2) * sqrt(n * sum y^2 - (sum y)^2))`
2. `r = (sum XY)/(sqrt(sum X^2) * sqrt(sum Y^2))`
3. `r = (n * sum dxdy - sum dx * sum dy)/( sqrt(n * sum dx^2 - (sum dx)^2) * sqrt(n * sum dy^2 - (sum dy)^2))`
4. Population `Cov(x,y)`
1. Population `Cov(x,y) = (sum (x-bar x)(y-bar y))/(n)`
2. Population `Cov(x,y) = (sum dxdy - (sum dx * sum dy)/n)/(n)`
3. Population `Cov(x,y) = (sum xy - (sum x * sum y)/n)/(n)`
5. Sample `Cov(x,y)`
1. Sample `Cov(x,y) = (sum (x-bar x)(y-bar y))/(n-1)`
2. Sample `Cov(x,y) = (sum dxdy - (sum dx * sum dy)/n)/(n-1)`
3. Sample `Cov(x,y) = (sum xy - (sum x * sum y)/n)/(n-1)`

Examples
2. Calculate Correlation Coefficient r without cov(x,y), Correlation Coefficient r with population cov(x,y), Correlation Coefficient r with sample cov(x,y) from the following data
XY
39
411
614
715
1016


Solution:
`x``y``x^2``y^2``x*y`
3998127
4111612144
6143619684
71549225105
1016100256160
---------------
`sum x=30``sum y=65``sum x^2=210``sum y^2=879``sum xy=420`


Correlation Coefficient r :
`r = (n * sum xy - sum x * sum y)/(sqrt(n * sum x^2 - (sum x)^2) * sqrt(n * sum y^2 - (sum y)^2))`

`=(5 * 420 - 30 * 65 )/(sqrt(5 * 210 - (30)^2) * sqrt(5 * 879 - (65)^2)`

`=(2100 - 1950)/(sqrt(1050 - 900) * sqrt(4395 - 4225))`

`=150/( sqrt(150) * sqrt(170))`

`=150/( 12.2474 * 13.0384)`

`=150/159.6872`

`=0.9393`




Correlation Coefficient r with Population Cov(x,y) :

Population `Cov(x,y) = (sum xy - (sum x * sum y)/n)/(n)`

`=(420 - (30 xx 65)/5)/5`

`=(420 - (1950)/5)/5`

`=(420 - 390)/5`

`=(30)/5`

`=6`


Population Standard deviation `sigma_x = sqrt((sum x^2 - (sum x)^2/n)/(n))`

`=sqrt((210 - (30)^2/5)/5)`

`=sqrt((210 - 180)/5)`

`=sqrt(30/5)`

`=sqrt(6)`

`=2.4495`

Population Standard deviation `sigma_y = sqrt((sum y^2 - (sum y)^2/n)/(n))`

`=sqrt((879 - (65)^2/5)/5)`

`=sqrt((879 - 845)/5)`

`=sqrt(34/5)`

`=sqrt(6.8)`

`=2.6077`

Now, `r = (cov(x,y))/(sigma_x * sigma_y)`

`= (6)/(2.4495 * 2.6077)`

`=0.9393`




Correlation Coefficient r with Sample Cov(x,y) :

Sample `Cov(x,y) = (sum xy - (sum x * sum y)/n)/(n-1)`

`=(420 - (30 xx 65)/5)/4`

`=(420 - (1950)/5)/4`

`=(420 - 390)/4`

`=(30)/4`

`=7.5`


Sample Standard deviation `sigma_x = sqrt((sum x^2 - (sum x)^2/n)/(n-1))`

`=sqrt((210 - (30)^2/5)/4)`

`=sqrt((210 - 180)/4)`

`=sqrt(30/4)`

`=sqrt(7.5)`

`=2.7386`

Sample Standard deviation `sigma_y = sqrt((sum y^2 - (sum y)^2/n)/(n-1))`

`=sqrt((879 - (65)^2/5)/4)`

`=sqrt((879 - 845)/4)`

`=sqrt(34/4)`

`=sqrt(8.5)`

`=2.9155`

Now, `r = (cov(x,y))/(sigma_x * sigma_y)`

`= (7.5)/(2.7386 * 2.9155)`

`=0.9393`




This material is intended as a summary. Use your textbook for detail explanation.
Any bug, improvement, feedback then Submit Here



2. Example-2 (Class-X & Y)
(Previous example)
4. Example-4 (X & Y)
(Next example)





Share this solution or page with your friends.


 
Copyright © 2024. All rights reserved. Terms, Privacy
 
 

.