Enter two data sets and this calculator will find the equation of the regression line and correlation coefficient. The calculator will generate a step by step explanation along with the graphic representation of the data sets and regression line.
solution
You entered the following data:
$$\begin{array}{c|cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc}X&95.42&95.88&93.05&94.58&98.22&99.65&98.75&100.21&97.02&96.48&95.85&97.44&95.66&96.99&94.71&98.66&95.32&95.00&90.65&88.41&87.02&86.05&82.78&81.52&79.81&80.40&79.53&80.25&79.72&81.40&80.19&80.66&80.26&80.32&82.14&81.54&83.38&83.40&81.81&83.17&82.00&79.23&79.87&80.16&79.99&80.03&81.22&82.71&81.75&83.13&78.85&79.14&78.79&79.42&80.52&78.49&76.31&79.08&74.17&74.04&74.64&74.70&73.11&76.07&76.92&77.86&79.29&81.27&77.46&78.94&83.25&81.66&86.28&86.67&81.99&81.29&80.44&79.65&78.22&74.94&76.47&76.86&78.22&78.45&80.42&79.43&84.78&85.89&88.15&86.46&82.15&86.70&86.34&79.36&77.50&73.42&72.80&72.95&72.72&72.17&73.75&75.28&76.70&76.17&76.46&77.62&80.75&80.66&81.69&82.25&81.30&82.66&83.50&84.43&83.43&82.85&85.11&85.68&85.02&85.09\\Y&1.1174&1.1311&1.1339&1.1099&1.1092&1.0859&1.0877&1.0736&1.1235&1.1221&1.1139&1.0995&1.1213&1.1149&1.0779&1.0837&1.1349&1.1621&1.2331&1.2472&1.2672&1.2901&1.3316&1.3539&1.3592&1.3732&1.3812&1.3822&1.3658&1.3610&1.3703&1.3492&1.3634&1.3347&1.3309&1.3080&1.3188&1.2982&1.3026&1.2963&1.3359&1.3288&1.3119&1.2827&1.2974&1.2855&1.2399&1.2288&1.2526&1.2788&1.3161&1.3201&1.3224&1.2904&1.3179&1.3555&1.3706&1.3770&1.4343&1.4264&1.4388&1.4348&1.4441&1.3996&1.3648&1.3359&1.3220&1.3660&1.3897&1.3067&1.2894&1.2767&1.2208&1.2565&1.3405&1.3568&1.3685&1.4272&1.4613&1.4911&1.4816&1.4561&1.4268&1.4087&1.4016&1.3650&1.3190&1.3049&1.2784&1.3238&1.3449&1.2732&1.3322&1.4369&1.4975&1.5769&1.5552&1.5557&1.5750&1.5526&1.4748&1.4717&1.4570&1.4683&1.4227&1.3896&1.3622&1.3715&1.3418&1.3511&1.3516&1.3241&1.3074&1.2998&1.3212&1.2881&1.2611&1.2730&1.2811&1.2683\end{array}$$The equation of the regression line is:
$$y~=~2.61 ~-~ 0.01558 \cdot x$$The graph of the regression line is:
explanation
We will find an equation of the regression line in 4 steps.
Step 1: Find $X \cdot Y$ and $X^2$ as it was done in the table below.
$X$ | $Y$ | $X\cdot Y$ | $X \cdot X$ |
95.42 | 1.1174 | 106.622308 | 9104.9764 |
95.88 | 1.1311 | 108.449868 | 9192.9744 |
93.05 | 1.1339 | 105.509395 | 8658.3025 |
94.58 | 1.1099 | 104.974342 | 8945.3764 |
98.22 | 1.1092 | 108.945624 | 9647.1684 |
99.65 | 1.0859 | 108.209935 | 9930.1225 |
98.75 | 1.0877 | 107.410375 | 9751.5625 |
100.21 | 1.0736 | 107.585456 | 10042.0441 |
97.02 | 1.1235 | 109.00197 | 9412.8804 |
96.48 | 1.1221 | 108.260208 | 9308.3904 |
95.85 | 1.1139 | 106.767315 | 9187.2225 |
97.44 | 1.0995 | 107.13528 | 9494.5536 |
95.66 | 1.1213 | 107.263558 | 9150.8356 |
96.99 | 1.1149 | 108.134151 | 9407.0601 |
94.71 | 1.0779 | 102.087909 | 8969.9841 |
98.66 | 1.0837 | 106.917842 | 9733.7956 |
95.32 | 1.1349 | 108.178668 | 9085.9024 |
95.00 | 1.1621 | 110.3995 | 9025 |
90.65 | 1.2331 | 111.780515 | 8217.4225 |
88.41 | 1.2472 | 110.264952 | 7816.3281 |
87.02 | 1.2672 | 110.271744 | 7572.4804 |
86.05 | 1.2901 | 111.013105 | 7404.6025 |
82.78 | 1.3316 | 110.229848 | 6852.5284 |
81.52 | 1.3539 | 110.369928 | 6645.5104 |
79.81 | 1.3592 | 108.477752 | 6369.6361 |
80.40 | 1.3732 | 110.40528 | 6464.16 |
79.53 | 1.3812 | 109.846836 | 6325.0209 |
80.25 | 1.3822 | 110.92155 | 6440.0625 |
79.72 | 1.3658 | 108.881576 | 6355.2784 |
81.40 | 1.3610 | 110.7854 | 6625.96 |
80.19 | 1.3703 | 109.884357 | 6430.4361 |
80.66 | 1.3492 | 108.826472 | 6506.0356 |
80.26 | 1.3634 | 109.426484 | 6441.6676 |
80.32 | 1.3347 | 107.203104 | 6451.3024 |
82.14 | 1.3309 | 109.320126 | 6746.9796 |
81.54 | 1.3080 | 106.65432 | 6648.7716 |
83.38 | 1.3188 | 109.961544 | 6952.2244 |
83.40 | 1.2982 | 108.26988 | 6955.56 |
81.81 | 1.3026 | 106.565706 | 6692.8761 |
83.17 | 1.2963 | 107.813271 | 6917.2489 |
82.00 | 1.3359 | 109.5438 | 6724 |
79.23 | 1.3288 | 105.280824 | 6277.3929 |
79.87 | 1.3119 | 104.781453 | 6379.2169 |
80.16 | 1.2827 | 102.821232 | 6425.6256 |
79.99 | 1.2974 | 103.779026 | 6398.4001 |
80.03 | 1.2855 | 102.878565 | 6404.8009 |
81.22 | 1.2399 | 100.704678 | 6596.6884 |
82.71 | 1.2288 | 101.634048 | 6840.9441 |
81.75 | 1.2526 | 102.40005 | 6683.0625 |
83.13 | 1.2788 | 106.306644 | 6910.5969 |
Step 2: Find the sum of every column:
$$ \sum{X} = 9938.49 ~,~ \sum{Y} = 158.4372 ~,~ \sum{X \cdot Y} = 13034.299457 ~,~ \sum{X^2} = 828736.4359 $$Step 3: Use the following equations to find $a$ and $b$:
$$ \begin{aligned} a &= \frac{\sum{Y} \cdot \sum{X^2} - \sum{X} \cdot \sum{XY} }{n \cdot \sum{X^2} - \left(\sum{X}\right)^2} = \frac{ 158.4372 \cdot 828736.4359 - 9938.49 \cdot 13034.299457}{ 120 \cdot 828736.4359 - 9938.49^2} \approx 2.61 \\ \\b &= \frac{ n \cdot \sum{XY} - \sum{X} \cdot \sum{Y}}{n \cdot \sum{X^2} - \left(\sum{X}\right)^2} = \frac{ 120 \cdot 13034.299457 - 9938.49 \cdot 158.4372 }{ 120 \cdot 828736.4359 - \left( 9938.49 \right)^2} \approx -0.01558\end{aligned}$$Step 4: Substitute $a$ and $b$ in regression equation formula
$$ \begin{aligned} y~&=~a ~+~ b \cdot x \\y~&=~2.61 ~-~ 0.01558 \cdot x\end{aligned}$$Consider the following set of points: ${(-3 , -4), \, (2 , 3), \, (7 , 11)}$
a) Find the regression line for the given data points.
b) Plot the given points and the regression line.
The values of $X$ and their corresponding values of $Y$ are shown in the table below:
$$ \begin{array}{c|ccccc} X & ~1~ & ~2~ & ~3~ & ~4~ & ~5 \\ Y & ~4~ & ~8~ & ~9~ & ~11~& ~16 \end{array} $$Find a Pearson correlation coefficient.
Please tell me how can I make this better.