You are on page 1of 4

EXCEL GUIDE: CORRELATION & REGRESSION EXAMPLE 1.

DATA
ID A B C D X .00 .00 8.00 8.00 Y .00 6.00 2.00 8.00

2. STATISTICS
Summary Output

Regression Statistics Multiple R 0.316228 R Square 0.1 Adjusted R Square -0.35 Standard Error 4.242641 Observations 4 ANOVA Regression Residual Total Intercept X df 1 2 3 Coefficient 3 0.25 S.E. SS 4 36 40 t Stat MS F Significant F 4 0.222222 0.683772 18

P-value Lower 95% Upper 95% 3 1 0.42265 -9.90797 15.90797 0.53033 0.471405 0.683772 -2.03183 2.531828

3. GRAPH

Grades on Quiz

10 8 6 4 2 0 0 2 4 6 8 10 Hours of Pra ctice

1. ENTERING THE DATA


Enter the scores in the worksheet as such:
X .00 .00 8.00 8.00 Y .00 6.00 2.00 8.00

X and Y will be the two variables that we want to find correlation.

2. COMPUTING THE STATISTICS


1. Go to Insert and select function wizard button fx, select the Statistical category, select CORREL, and click Next. 2. Enter the range A2:A5 in the array 1 box. You can also click and drag over the range for X instead of entering manually. 3. Enter the range B2:B5 in the array 2 box. You can also click and drag over the range for Y instead of entering manually. 4. Click Finish and an r of .31 is returned. 5. In the Main Menu Bar, click on Tools Data Analysis. 6. In the Data Analysis window, select Regression and click OK. 7. Input Y range: Enter $B$1:$B$5 or drag over the cells of Y. 8. Input X range: Enter $A$1:$A$5 or drag over the cells of X. 9. Labels should be checked because we include the variable names in cells A1 and

B1. These labels will be used in the output. 10. Constant is Zero is not checked because we do not want to force the regression line through the origin. 11. Confidence Level is checked and a value of 90 is entered int eh space to the right of Confidence Level. If it is not checked, the default value of 95% will be utilized, and we will see the 95% boundaries reported twice in the regression output. 12. Type $C$1 for Output options. 13. Residuals refer to the difference between the actual Y data points and the Y values predicted by the regression equation. We did not ask for any output in this section. 14. Normal Probability will generate a chart of normal probabilities. We did not select this output. 15. Click OK and the output shown above will be generated.

3. GRAPHING THE DATA


Excels Chart Wizard provides an efficient way to produce a scatterplot of two variables. The procedure will not work, however, unless the two variables are adjacent to each other in the worksheet. 1. Click on the Insert on the Menu bar, select Chart and select As New Sheet. 2. Click and drag over the range of numerical values in columns A and B. 3. Select XY(Scatter) and click Next. 4. Select Format 3 and click next. 5. Select Data Series in Columns, and Use First 1 columns for X Data, 0 Rows for Legend Text. Then Click Next. 6. Specify the legend, chart title, X-axis title, and Y-axis title in the dialog box. 7. The completed scatterplpot is shown at the top of this page. 8. To add the regression line simply click on one of the data points on the chart with the left mouse button. Square handles will appear on all the points. Now click the right mouse button, a menu will appear. Select the Add Trendline command. 9. Select the right group (Group 1) and click OK.

EDITING THE GRAPH


Often the graph will not appear exactly as you wish. However, it's easy to change colors, markers, axes, etc. Using the mouse, move the cursor anywhere on the graph you want to edit and double click.

A new window will appear and you can make your own changes on the graph.

You might also like