Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision...

42
Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction to Linear Regression and Correlation Analysis By Groebner, Shannon, Fry, & Smith Prentice-Hall Publishing Company Copyright, 2005

Transcript of Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision...

Page 1: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Guide to Using Excel For Basic Statistical Applications

Guide to Using Excel For Basic Statistical Applications

To Accompany

Business Statistics: A Decision Making Approach, 6th Ed.

Chapter 13:

Introduction to Linear Regression and Correlation Analysis

By

Groebner, Shannon, Fry, & SmithPrentice-Hall Publishing Company

Copyright, 2005

Page 2: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Chapter 13 Excel Examples

Correlation CoefficientMidwest Distribution

Regression AnalysisMidwest Distribution

• Regression AnalysisFitzpatrick and Associates

Regression Analysis for Description Car Mileage

Page 3: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Chapter 13 Excel Examples

Regression Analysis for Prediction

Freedom HospitalResidual Analysis

Freedom Hospital

Page 4: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Correlation Analysis - Midwest Distribution

Issue:

The company wants to analyze the relationship between salary and years with the company.

Objective:

Use Excel to help test whether a significant relations exists between salary and years with the company. Data file is Midwest.xls

Page 5: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Open File Midwest.xls

To construct the scatter diagram see the Personal Computers tutorial in Chapter 2.

Correlation Analysis – Midwest Distribution.

Page 6: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

First click on Tools, then Data Analysis and finally on Correlation.

Correlation Analysis – Midwest Distribution.

Page 7: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Define ranges for Variables. Click on O.K.

Correlation Analysis – Midwest Distribution.

Page 8: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

The Excel output shows the correlation between Sales and Years with Midwest.

Correlation Analysis – Midwest Distribution.

Page 9: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Regression Analysis - Midwest DistributionRegression Analysis - Midwest Distribution

Issue:

The marketing manager wants to determine the relationship between sales and years with the company.

Objective:

Use Excel to test whether the apparent linear relationship is statistically significant. Data file is Midwest.xls

Page 10: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Open File Midwest.xls

Regression Analysis – Midwest Distribution

Page 11: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Click on Tools, then Data Analysis and finally Regression

Regression Analysis – Midwest Distribution

Page 12: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Identify Data ranges for the X and Y variables. Click on O.K.

Regression Analysis – Midwest Distribution

Page 13: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

The output shows the correlation coefficient and the coefficients for the regression equation.

Regression Analysis – Midwest Distribution

Page 14: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

SSE=SSR + SSE F= MSR/MSE

MS= Mean Squares

Page 15: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Regression Analysis - Fitzpatrick & AssociatesRegression Analysis - Fitzpatrick & Associates

Issue:

The Fitzpatrick analysts want to model the relationship between profits and number of employees.

Objective:

Use Excel to test whether the apparent linear relationship is statistically significant. Data file is Fortune 50.xls

Page 16: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Open File Fortune 50.xls

Regression Analysis – Fitzpatrick & Associates

Page 17: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Click on Chart Wizard button, then XY Scatter

Regression Analysis – Fitzpatrick & Associates

Page 18: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Define Data ranges in chart wizard. Note: Excel requires the data to be in adjacent columns with the X variable on the left.

Regression Analysis – Fitzpatrick & Associates

Page 19: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Finish steps in Chart Wizard.

Regression Analysis – Fitzpatrick & Associates

Page 20: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

To find regression model, return to Data sheet.

Regression Analysis – Fitzpatrick & Associates

Page 21: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Click on Tools, then Data Analysis and finally Regression

Regression Analysis – Fitzpatrick & Associates

Page 22: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Identify Data ranges for the X and Y variables. Click on O.K.

Regression Analysis – Fitzpatrick & Associates

Page 23: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

The output shows the correlation coefficient and the coefficients for the regression equation.

Regression Analysis – Fitzpatrick & Associates

Page 24: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Regression Analysis - Car MileageRegression Analysis - Car Mileage

Issue:

Analysts want to determine the relationship between EPA highway mileage and automobile horsepower.

Objective:

Use Excel to test whether the apparent linear relationship is statistically significant. Data file is Automobiles.xls

Page 25: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Open File Automobiles.xls

Regression Analysis – Car Mileage

Page 26: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Click on Tools, then Data Analysis and finally Regression

Regression Analysis – Car Mileage

Page 27: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Identify Data ranges for the X and Y variables. Click on O.K.

Regression Analysis – Car Mileage

Page 28: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

The output shows the correlation coefficient and the coefficients for the regression equation.

Regression Analysis – Car mileage

Page 29: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Regression Analysis for Prediction - Freedom HospitalRegression Analysis for Prediction - Freedom Hospital

Issue:

The administrator has been requested by the hospital’s board of directors to develop a model that can be used to predict the total charges for a geriatric patient.

Objective:

Use Excel to develop a statistically significant prediction model. Data file is Patients.xls

Page 30: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Open File Patients.xls

File contains values for 138 patients.

Regression Analysis for Prediction – Freedom Hospital

Page 31: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

To develop the model first click on Tools, then Data Analysis and finally on Regression.

Regression Analysis for Prediction – Freedom Hospital

Page 32: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Define range for Variables and select the Alpha value (.05). Click on O.K.

Regression Analysis for Prediction – Freedom Hospital

Page 33: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

The Excel output shows both the correlation coefficient and the coefficients of the linear regression model.

Regression Analysis for Prediction – Freedom Hospital

Page 34: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

To determine prediction interval, return to data sheet, click on PHStat, then Regression and finally Simple Linear Regression.

Regression Analysis for Prediction – Freedom Hospital

Page 35: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Specify the Cell Range for the X and Y variables. Then click the Confidence Interval box and specify the value for X and the Confidence Level.

Regression Analysis for Prediction – Freedom Hospital

Page 36: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

The output shows the 95% confidence interval for both the Average Value of Y and for an Individual Value of Y.

Regression Analysis for Prediction – Freedom Hospital

Page 37: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Issue:

The administrators want to determine whether the prediction model developed is a valid use of regression analysis or whether it violates some of the necessary assumptions. Objective:

Use Excel to analyze the residuals from the model. Data file is Patients.xls

Residual Analysis - Freedom HospitalResidual Analysis - Freedom Hospital

Page 38: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Open file Patients.xls

Residual Analysis – Freedom Hospital

Page 39: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

First click on Tools, then Data Analysis and then on Regression.

Residual Analysis – Freedom Hospital

Page 40: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

Define range for X and Y Variables and then check boxes for Residuals and Residual Plots.

Residual Analysis – Freedom Hospital

Page 41: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

At the bottom of the regression output (note the row number) the residual for each observation is given.

Residual Analysis – Freedom Hospital

Page 42: Guide to Using Excel For Basic Statistical Applications To Accompany Business Statistics: A Decision Making Approach, 6th Ed. Chapter 13: Introduction.

The regression output will also plot the residuals.

Residual Analysis – Freedom Hospital