Calculate karl pearson's coefficient of correlation from the following data :
X - 105, 120, 95, 150, 130
Y - 100, 115, 110, 135, 115
The coefficient of correlation is calculated with the formula:
xˉ=∑xin=105+120+95+150+1305=120\bar x = \frac{\sum x_i}{n}=\frac{105+120+95+150+130}{5}= 120xˉ=n∑xi=5105+120+95+150+130=120
yˉ=∑yin=100+115+110+135+1155=115\bar y = \frac{\sum y_i}{n}=\frac{100+115+110+135+115}{5}= 115yˉ=n∑yi=5100+115+110+135+115=115
r=(105−120)(100−115)+(120−120)(115−115)+(95−120)(110−115)+(150−120)(135−115)+(130−120)(115−115)((105−120)2+(120−120)2+(95−120)2+(150−120)2+(130−120)2)((100−115)2+(115−115)2+(110−115)2+(135−115)2+(115−115)2)=r=\frac{(105-120)(100-115)+(120-120)(115 - 115)+(95-120)(110 - 115)+(150-120)(135 - 115)+(130-120)(115 - 115)}{\sqrt{((105-120)^2+(120-120)^2+(95-120)^2+(150-120)^2+(130-120)^2)((100 - 115)^2+(115 - 115)^2+(110 - 115)^2+(135 - 115)^2+(115 - 115)^2)}}=r=((105−120)2+(120−120)2+(95−120)2+(150−120)2+(130−120)2)((100−115)2+(115−115)2+(110−115)2+(135−115)2+(115−115)2)(105−120)(100−115)+(120−120)(115−115)+(95−120)(110−115)+(150−120)(135−115)+(130−120)(115−115)= =(−15)(−15)+0+(−25)(−5)+30⋅20+0((−15)2+02+(−25)2+302+102)((−15)2+02+(−5)2+202+02)=225+125+600(225+625+900+100)(225+25+400)=9501850⋅650=0.866=\frac{(-15)(-15)+0+(-25)(-5)+30\cdot20+0}{\sqrt{((-15)^2+0^2+(-25)^2+30^2+10^2)((-15)^2+0^2+(-5)^2+20^2+0^2)}} =\frac{225+125+600}{\sqrt{(225+625+900+100)(225+25+400)}} =\frac{950}{\sqrt{1850\cdot650}}=0.866=((−15)2+02+(−25)2+302+102)((−15)2+02+(−5)2+202+02)(−15)(−15)+0+(−25)(−5)+30⋅20+0=(225+625+900+100)(225+25+400)225+125+600=1850⋅650950=0.866
Answer: 0.866
Need a fast expert's response?
and get a quick answer at the best price
for any assignment or question with DETAILED EXPLANATIONS!
Comments
Leave a comment