Copyright 2013 by Laura Schultz. All rights reserved. Page 1 of 6

Similar documents
Copyright 2013 by Laura Schultz. All rights reserved. Page 1 of 7

Copyright 2007 by Laura Schultz. All rights reserved. Page 1 of 5

Dealing with Data in Excel 2010

Chapter 7: Simple linear regression Learning Objectives

Univariate Regression

Example: Boats and Manatees

WEB APPENDIX. Calculating Beta Coefficients. b Beta Rise Run Y X

Doing Multiple Regression with SPSS. In this case, we are interested in the Analyze options so we choose that menu. If gives us a number of choices:

hp calculators HP 50g Trend Lines The STAT menu Trend Lines Practice predicting the future using trend lines

Simple linear regression

Regression Analysis: A Complete Example

Curve Fitting in Microsoft Excel By William Lee

Calculator Notes for the TI-Nspire and TI-Nspire CAS

Simple Linear Regression, Scatterplots, and Bivariate Correlation

Chapter 23. Inferences for Regression

Chapter 10. Key Ideas Correlation, Correlation Coefficient (r),

Exercise 1.12 (Pg )

Calibration and Linear Regression Analysis: A Self-Guided Tutorial

Simple Regression Theory II 2010 Samuel L. Baker

Descriptive Statistics

TI-Inspire manual 1. Instructions. Ti-Inspire for statistics. General Introduction

The Dummy s Guide to Data Analysis Using SPSS

Elements of a graph. Click on the links below to jump directly to the relevant section

1. What is the critical value for this 95% confidence interval? CV = z.025 = invnorm(0.025) = 1.96

Relationships Between Two Variables: Scatterplots and Correlation

Section 1.1 Linear Equations: Slope and Equations of Lines

Scatter Plot, Correlation, and Regression on the TI-83/84

EXCEL Tutorial: How to use EXCEL for Graphs and Calculations.

Data analysis and regression in Stata

2. Simple Linear Regression

X X X a) perfect linear correlation b) no correlation c) positive correlation (r = 1) (r = 0) (0 < r < 1)

Activity 5. Two Hot, Two Cold. Introduction. Equipment Required. Collecting the Data

KSTAT MINI-MANUAL. Decision Sciences 434 Kellogg Graduate School of Management

CHAPTER 13 SIMPLE LINEAR REGRESSION. Opening Example. Simple Regression. Linear Regression

Regression III: Advanced Methods

Homework 11. Part 1. Name: Score: / null

Using R for Linear Regression

Lecture 11: Chapter 5, Section 3 Relationships between Two Quantitative Variables; Correlation

Module 5: Statistical Analysis

Business Valuation Review

Comparing Means in Two Populations

Data Analysis Tools. Tools for Summarizing Data

Graphing Quadratic Functions

MTH 140 Statistics Videos

Correlation and Regression

ch12 practice test SHORT ANSWER. Write the word or phrase that best completes each statement or answers the question.

The importance of graphing the data: Anscombe s regression examples

TI-83/84 Plus Graphing Calculator Worksheet #2

Basic Graphing Functions for the TI-83 and TI-84

Regression and Correlation

11. Analysis of Case-control Studies Logistic Regression

Section 1.5 Linear Models

Statistics courses often teach the two-sample t-test, linear regression, and analysis of variance

Transforming Bivariate Data

USING A TI-83 OR TI-84 SERIES GRAPHING CALCULATOR IN AN INTRODUCTORY STATISTICS CLASS

Because the slope is, a slope of 5 would mean that for every 1cm increase in diameter, the circumference would increase by 5cm.

(More Practice With Trend Forecasts)

We are often interested in the relationship between two variables. Do people with more years of full-time education earn higher salaries?

Texas Instruments BAII Plus Tutorial for Use with Fundamentals 11/e and Concise 5/e

Bill Burton Albert Einstein College of Medicine April 28, 2014 EERS: Managing the Tension Between Rigor and Resources 1

Instat Tutorial. by Roger Stern, Sandro Leidi, Ian Dale and Colin Grayer. Contents. Installation 2

Bowerman, O'Connell, Aitken Schermer, & Adcock, Business Statistics in Practice, Canadian edition

Introduction to the TI-Nspire CX

Chapter 13 Introduction to Linear Regression and Correlation Analysis

5. Correlation. Open HeightWeight.sav. Take a moment to review the data file.

Unit 31 A Hypothesis Test about Correlation and Slope in a Simple Linear Regression

There are six different windows that can be opened when using SPSS. The following will give a description of each of them.

This chapter will demonstrate how to perform multiple linear regression with IBM SPSS

How Many Drivers? Investigating the Slope-Intercept Form of a Line

Using Excel for Statistical Analysis

table to see that the probability is (b) What is the probability that x is between 16 and 60? The z-scores for 16 and 60 are: = 1.

Section 14 Simple Linear Regression: Introduction to Least Squares Regression

Analysis of Variance ANOVA

Academic Support Center. Using the TI-83/84+ Graphing Calculator PART II

Formula for linear models. Prediction, extrapolation, significance test against zero slope.

Once saved, if the file was zipped you will need to unzip it. For the files that I will be posting you need to change the preferences.

SPSS Tutorial, Feb. 7, 2003 Prof. Scott Allard

Simple Predictive Analytics Curtis Seare

Table of Contents. Preface

Using Excel for inferential statistics

Slope-Intercept Equation. Example

SPSS Guide: Regression Analysis

PERFORMING REGRESSION ANALYSIS USING MICROSOFT EXCEL

Slope & y-intercept Discovery Activity

Curve Fitting with Maple

When to use Excel. When NOT to use Excel 9/24/2014

1/27/2013. PSY 512: Advanced Statistics for Psychological and Behavioral Research 2

Your Name: Section: INTRODUCTION TO STATISTICAL REASONING Computer Lab Exercise #5 Analysis of Time of Death Data for Soldiers in Vietnam

the Median-Medi Graphing bivariate data in a scatter plot

Straightening Data in a Scatterplot Selecting a Good Re-Expression Model

TI-Inspire manual 1. I n str uctions. Ti-Inspire for statistics. General Introduction

MULTIPLE REGRESSION EXAMPLE

Multiple Regression in SPSS This example shows you how to perform multiple regression. The basic command is regression : linear.

DATA INTERPRETATION AND STATISTICS

Linear Regression. use waist

TI-nspire CAS Replacement calculator screens for the Core material

SPSS Manual for Introductory Applied Statistics: A Variable Approach

EL-9650/9600c/9450/9400 Handbook Vol. 1

Transcription:

Using Your TI-NSpire Calculator: Linear Correlation and Regression Dr. Laura Schultz Statistics I This handout describes how to use your calculator for various linear correlation and regression applications. For illustration purposes, we will work with a data set consisting of the Amazon.com prices of ten commonly adopted introductory statistics textbooks (in $) paired with the page count for each textbook. You can find this data set in the Appendix at the end of this handout. 1. Before we can get started, you will need to enter the textbook data into your calculator. Start a new document from the home screen and select 4: Add Lists & Spreadsheet. We will be using this data set for several different applications, so it will be helpful to press /» and save your document with an informative file name, like textbooks. Name list A pages and proceed to enter the page count data into this list. Name list B price and enter the Amazon.com prices into this list. Check over your lists to make sure you didn t enter any incorrect data values. Note that each pages value must be paired with the corresponding price for a given textbook. 2. Generating a Scatterplot. To get a sense of the data, start by generating a scatterplot. Press the ~ key and select 4: Insert followed by 7: Data & Statistics. Using the touch pad, click at the bottom of the screen and specify that the x- variable will be pages. A dot plot will form showing the distribution of the x-variable. Click on the left-side of the screen and specify price as the y-variable. Your calculator will produce the scatterplot shown to the right. What can you tell from the scatterplot? Does there appear to be a linear correlation between pages and price? If so, is it positive or negative? How strong does the correlation appear to be? Copyright 2013 by Laura Schultz. All rights reserved. Page 1 of 6

3. The next step is to find the linear correlation coefficient (r) and the linear regression equation. The Linear Reg t Test command on your calculator provides one-stop shopping for answering these and other questions relating to linear correlation and regression. Press the ~ key and select 4: Insert followed by 3: Calculator. Press b and select 6: Statistics followed by 7: Stat Tests. Choose option A: Linear Reg t Test. 4. You will be prompted for the following information: X List: Enter the name of the list containing the predictor (x) variable. For this example, select pages and press e. Y List: Enter the name of the list containing the response (y) variable. For this example, select price and press e. Save RegEqn to: Here you can specify one of the builtin functions as a place to store the regression equation that is generated. Doing so will allow you to use the regression equation to make predictions later on. Alternate Hyp: Select the desired alternative hypothesis. (The model utility test for simple linear regression is covered by the Statistics II course at Rowan.) For our purposes, select Ha: β & ρ 0 and press e. Highlight OK and press. 5. Your calculator will return two screens full of output; use the touch pad arrow keys to scroll through all of the output. Let s start by finding the linear correlation coefficient (r) for our data. You will need to scroll down to the bottom of the second screen to find r. For this example, r = -0.747. What does r tell us? First of all, its sign tells us that there likely is a negative correlation between page count and the price of introductory statistics textbooks sold by Amazon.com. The slope of the regression line will also be negative. Second, because r is fairly close to -1, we can conclude that there is a moderately strong negative correlation displayed by our sample data. Copyright 2013 by Laura Schultz. All rights reserved. Page 2 of 6

6. A model utility test asks whether there a useful linear relationship between the page count of an introductory statistics textbook and its price on Amazon.com. That is, can we conclude that the slope (β) of the population regression line is not equal to 0? The linear regression t test calculator output can be used to address this question. You would report the results of the t test for this example as t 8 = -3.1775, P =.0130 (two-tailed). Note that I reported the degrees of freedom as a subscript (df = n - 2). Round the t-test statistic to 4 decimal places and the P-value to 3 significant figures. Given that the P-value is less than the significance level of α =.05, we can conclude that there is a useful linear relationship between the page count of an introductory statistics textbook and its price on Amazon.com. (The details of the model utility test for simple linear regression are covered by Rowan s Statistics II course; we will not use this test in Statistics I.) 7. The coefficient of determination (r 2 ) tells us how much of the variability in y can be explained by the linear relationship between x and y. By convention, r 2 is reported as a percentage. For our example, r 2 = 55.8%. What does this mean? 55.8% of the observed variability in introductory statistics textbook prices on Amazon.com can be attributed to the linear relationship between the page count and the textbook price. 8. We can also use the calculator output to construct the linear regression equation for our data. There are two methods for doing so. First, note that the previous calculator displays indicate that ReqEqn = a + b x. Your calculator reports values for both a (the y-intercept) and b (the slope). The regression equation will also be displayed when you add a regression line to your scatterplot. In either case, round the y-intercept and slope values to one more decimal place than you started with for y when you report the linear regression equation. The linear regression equation for our sample data is ŷ = 243.957 0.111x. 9. Note that the previous output screen also included the standard deviation of the residuals (se in textbook; s on calculator display), also referred to as the standard error of the estimate. For our data set, s = $9.64. (Note that s has the same units as y.) What does this mean? The typical discrepancy between an observed textbook price and the value predicted by the regression equation is $9.64. 10. What is the marginal change in textbook price for each additional page? Marginal change is simply the slope of the regression line. Hence, the marginal change for our example is -0.111 dollars/page. In other words, the price of an introductory statistics textbook decreases by an average of $0.111 for each additional page. Copyright 2013 by Laura Schultz. All rights reserved. Page 3 of 6

11. Let s add a regression line to the scatterplot. Use the touch pad to navigate to the screen containing your scatterplot (1.2). Then, press b and select 4: Analyze followed by 6: Regression. Choose option 2: Show Linear (a +bx). Your calculator will return the scatterplot with the regression line in place and also report the regression equation. Note how well the regression line fits our data. The stronger the linear correlation, the closer the data points will cluster along the regression line. 12. Making predictions from a regression equation. Let s use the regression equation to predict what the price would be for an introductory statistics textbook with 850 pages. Use the touch pad to return to your calculator window (or add a new calculator window). Press the h key and select the function where you stored the regression equation; I used f1. Then, type in the value of x that you wish to use, 850 in this case, and press. Your calculator will return the predicted y value for an x value of 850. Hence, we predict that an 850-page introductory statistics textbook will cost $149.265 on Amazon.com. (If necessary, round your predictions to one more decimal place than we started with for y.) How to Generate a Residual Plot A residual plot is a scatterplot of each x value plotted against its corresponding residual. Recall that a residual is the difference between an observed y value and the corresponding predicted y value (e = y ŷ ). It is important to examine the residual plot to look for any potential problems. Ideally, a residual plot will contain no pattern at all. If a pattern does appear (such as a curve in the plot or an uneven distribution of the points), then you should hesitate to use the regression equation to make predictions. Any pattern in the residuals is an indication that the relationship between x and y is not linear and that simple linear correlation and regression techniques are not appropriate. A residual plot can also be helpful for identifying outliers and high leverage points. Copyright 2013 by Laura Schultz. All rights reserved. Page 4 of 6

1. Whenever you use your calculator to fit a regression line, the residuals are automatically computed and stored in a variable named resid. You can produce a residual plot by following the directions on page 1 of this handout for producing a scatterplot. Choose the resid variable for your y-axis variable (instead of price) and using pages as the x-axis variable. Give this a try. 2. The TI-NSpire provides an easier method for generating a residual plot. Use the touch pad to return to your fitted scatterplot (1.2). Press b and select 4: Analyze followed by 7: Residuals. Choose option 2: Show Residual Plot. A residual plot will be added beneath the fitted scatterplot. Both plots share the same x-axis (pages). Do you see any problems with the residual plot? 3. Repeat the steps above, but choose option 1: Show Residual Squares this time. The resulting graph shows the squared residual for each data point. Recall that we are technically plotting the least-squares regression line. This is the line that is guaranteed to result in the smallest possible sum of the squared residuals ( sum of squares ). In other words, the leastsquares regression line is the one which minimizes the error between the observed and expected y-values. Copyright 2013 by Laura Schultz. All rights reserved. Page 5 of 6

1 2 3 4 5 6 7 8 9 10 Appendix: Data Set Data obtained from Amazon.com on 24 July 2013 Textbook Pages Amazon Price Moore/McCabe/Craig Bluman Sullivan Triola Weiss DeVeaux/Velleman/Bock Peck/Olsen/Devore Agresti and Franklin McClave and Sincich Utts and Heckard 694 896 960 840 896 976 944 832 814 752 153.33 134.49 142.56 147.56 150.31 131.99 133.99 147.09 166.25 173.49 Copyright 2013 by Laura Schultz. All rights reserved. Page 6 of 6