Correlation and regression calculator

Enter two data sets and this calculator will find the equation of the regression line and corelation coefficient. The calculator will generate a step by step explanation along with the graphic representation of the data sets and regression line.

Result:

You entered the following data:

$$\begin{array}{c|cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc}X&48.91&49.10&45.92&38.34&33.75&33.62&37.04&41.65&46.59&45.09&49.20&47.12&59.47&60.30&59.63&47.60&49.76&48.24&53.27&66.15&80.54&91.16&95.96&98.17&105.37&102.71&99.74&101.58&102.59&97.49&98.42&92.72&96.38&102.33&107.65&105.03&96.56&91.97&93.46&97.23&92.05&97.49&91.82&88.91&86.24&92.19&96.49&88.06&84.96&86.53&104.87&103.02&107.07&98.48&98.83&100.36&93.19&79.20&88.81&95.70&95.42&102.70&113.93&106.72&96.97&92.19&91.38&84.11&81.43&79.97&71.92&78.95&75.63&73.97&86.15&83.76&79.66&72.89&79.36&77.28&77.00&70.61&69.96&69.45&69.89&66.31&51.12&49.66&44.76&41.68&44.60&54.43&67.81&100.64&115.46&124.08&140.00&127.35&113.46&101.58&101.84&91.75&95.98&88.71&94.53&81.66&74.04&78.21&70.68&64.01&65.71&65.87&61.79&58.14&61.05&63.13&58.73&62.91&70.26&74.40\\Y&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\end{array}$$

The equation of the regression line is:

$$y~=~102.4 ~-~ 0.2447 \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$ 
48.91 95.42 4666.9922 2392.1881
49.10 95.88 4707.708 2410.81
45.92 93.05 4272.856 2108.6464
38.34 94.58 3626.1972 1469.9556
33.75 98.22 3314.925 1139.0625
33.62 99.65 3350.233 1130.3044
37.04 98.75 3657.7 1371.9616
41.65 100.21 4173.7465 1734.7225
46.59 97.02 4520.1618 2170.6281
45.09 96.48 4350.2832 2033.1081
49.20 95.85 4715.82 2420.64
47.12 97.44 4591.3728 2220.2944
59.47 95.66 5688.9002 3536.6809
60.30 96.99 5848.497 3636.09
59.63 94.71 5647.5573 3555.7369
47.60 98.66 4696.216 2265.76
49.76 95.32 4743.1232 2476.0576
48.24 95.00 4582.8 2327.0976
53.27 90.65 4828.9255 2837.6929
66.15 88.41 5848.3215 4375.8225
80.54 87.02 7008.5908 6486.6916
91.16 86.05 7844.318 8310.1456
95.96 82.78 7943.5688 9208.3216
98.17 81.52 8002.8184 9637.3489
105.37 79.81 8409.5797 11102.8369
102.71 80.40 8257.884 10549.3441
99.74 79.53 7932.3222 9948.0676
101.58 80.25 8151.795 10318.4964
102.59 79.72 8178.4748 10524.7081
97.49 81.40 7935.686 9504.3001
98.42 80.19 7892.2998 9686.4964
92.72 80.66 7478.7952 8596.9984
96.38 80.26 7735.4588 9289.1044
102.33 80.32 8219.1456 10471.4289
107.65 82.14 8842.371 11588.5225
105.03 81.54 8564.1462 11031.3009
96.56 83.38 8051.1728 9323.8336
91.97 83.40 7670.298 8458.4809
93.46 81.81 7645.9626 8734.7716
97.23 83.17 8086.6191 9453.6729
92.05 82.00 7548.1 8473.2025
97.49 79.23 7724.1327 9504.3001
91.82 79.87 7333.6634 8430.9124
88.91 80.16 7127.0256 7904.9881
86.24 79.99 6898.3376 7437.3376
92.19 80.03 7377.9657 8498.9961
96.49 81.22 7836.9178 9310.3201
88.06 82.71 7283.4426 7754.5636
84.96 81.75 6945.48 7218.2016
86.53 83.13 7193.2389 7487.4409

Step 2: Find the sum of every column:

$$ \sum{X} = 9599.72 ~,~ \sum{Y} = 9938.49 ~,~ \sum{X \cdot Y} = 780467.5162 ~,~ \sum{X^2} = 827573.9628 $$

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{ 9938.49 \cdot 827573.9628 - 9599.72 \cdot 780467.5162}{ 120 \cdot 827573.9628 - 9599.72^2} \approx 102.4 \\ \\b &= \frac{ n \cdot \sum{XY} - \sum{X} \cdot \sum{Y}}{n \cdot \sum{X^2} - \left(\sum{X}\right)^2} = \frac{ 120 \cdot 780467.5162 - 9599.72 \cdot 9938.49 }{ 120 \cdot 827573.9628 - \left( 9599.72 \right)^2} \approx -0.2447\end{aligned}$$

Step 4: Substitute $a$ and $b$ in regression equation formula

$$ \begin{aligned} y~&=~a ~+~ b \cdot x \\y~&=~102.4 ~-~ 0.2447 \cdot x\end{aligned}$$

Report an Error !

Script name : correlation-and-regression-calculator

Form values: 48.91,49.10,45.92,38.34,33.75,33.62,37.04,41.65,46.59,45.09,49.20,47.12,59.47,60.30,59.63,47.60,49.76,48.24,53.27,66.15,80.54,91.16,95.96,98.17,105.37,102.71,99.74,101.58,102.59,97.49,98.42,92.72,96.38,102.33,107.65,105.03,96.56,91.97,93.46,97.23,92.05,97.49,91.82,88.91,86.24,92.19,96.49,88.06,84.96,86.53,104.87,103.02,107.07,98.48,98.83,100.36,93.19,79.20,88.81,95.70,95.42,102.70,113.93,106.72,96.97,92.19,91.38,84.11,81.43,79.97,71.92,78.95,75.63,73.97,86.15,83.76,79.66,72.89,79.36,77.28,77.00,70.61,69.96,69.45,69.89,66.31,51.12,49.66,44.76,41.68,44.60,54.43,67.81,100.64,115.46,124.08,140.00,127.35,113.46,101.58,101.84,91.75,95.98,88.71,94.53,81.66,74.04,78.21,70.68,64.01,65.71,65.87,61.79,58.14,61.05,63.13,58.73,62.91,70.26,74.40 , 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 , reg

Comment (optional)

Share Result

Share this result with others by using the link below.

You can click here to verify link or you can just copy and paste link wherever you need it.

Correlation and Regression Calculator
Input X and Y values separated by comma or blank space
show help ↓↓ examples ↓↓
Use data grit to input x and y values
Find the equation of the regression line
Find the corelation coefficient
Hide steps
working...
examples
example 1:ex 1:

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.

example 2:ex 2:

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.

Quick Calculator Search

Was this calculator helpful?

Yes No
211 190 431 solved problems