Saturday, August 31, 2019
Spss Regression
Simple Linear Regression in SPSS 1. STAT 314 Ten Corvettes between 1 and 6 years old were randomly selected from last yearââ¬â¢s sales records in Virginia Beach, Virginia. The following data were obtained, where x denotes age, in years, and y denotes sales price, in hundreds of dollars. x y a. b. c. d. e. f. g. h. i. j. k. l. m. 6 125 6 115 6 130 4 160 2 219 5 150 4 190 5 163 1 260 2 260 Graph the data in a scatterplot to determine if there is a possible linear relationship. Compute and interpret the linear correlation coefficient, r. Determine the regression equation for the data.Graph the regression equation and the data points. Identify outliers and potential influential observations. Compute and interpret the coefficient of determination, r2. Obtain the residuals and create a residual plot. Decide whether it is reasonable to consider that the assumptions for regression analysis are met by the variables in questions. At the 5% significance level, do the data provide sufficient evidence to conclude that the slope of the population regression line is not 0 and, hence, that age is useful as a predictor of sales price for Corvettes? Obtain and interpret a 95% confidence interval for the slope, ? of the population regression line that relates age to sales price for Corvettes. Obtain a point estimate for the mean sales price of all 4-year-old Corvettes. Determine a 95% confidence interval for the mean sales price of all 4-year-old Corvettes. Find the predicted sales price of Jack Smithââ¬â¢s 4-year-old Corvette. Determine a 95% prediction interval for the sales price of Jack Smithââ¬â¢s 4-year-old Corvette. Note that the following steps are not required for all analysesâ⬠¦only perform the necessary steps to complete your problem. Use the above steps as a guide to the correct SPSS steps. 1.Enter the age values into one variable and the corresponding sales price values into another variable (see figure, below). 2. Select Graphs ? Legacy Dialogs ? Scatte r/Dotâ⬠¦ (select Simple then click the Define button) with the Y Axis variable (Price) and the X Axis variable (Age) entered (see figures, below). Click ââ¬Å"Titlesâ⬠¦Ã¢â¬ to enter a descriptive title for your graph, and click ââ¬Å"Continueâ⬠. Click ââ¬Å"OKâ⬠. Your output should look similar to the figure below. a. Graph the data in a scatterplot to determine if there is a possible linear relationship. The points seem to follow a somewhat linear pattern with a negative slope. . Select Analyze ? Correlate ? Bivariateâ⬠¦ (see figure, below). 4. Select ââ¬Å"Ageâ⬠and ââ¬Å"Priceâ⬠as the variables, select ââ¬Å"Pearsonâ⬠as the correlation coefficient, and click ââ¬Å" ââ¬Å"OKâ⬠(see the left figure, below). b. Compute and interpret the linear correlation coefficient, r. The correlation coefficient is ââ¬â0. 9679 (see the right figure, above). This value of r suggests a strong negative linear correlation since the value is n egative and close to ââ¬â1. Since the above value of r suggests a strong negative linear correlation, the data points should be clustered closely about a negatively sloping regression line.This is consistent with the graph obtained above. Therefore, since we see a strong negative linear relationship between Age and Price, linear regression analysis can continue. 5. Since we eventually want to predict the price of 4-year-old Corvettes (parts jââ¬âm), enter the number ââ¬Å"4â⬠in the ââ¬Å"Ageâ⬠variable column of the data window after the last row. Enter a ââ¬Å". â⬠for the corresponding ââ¬Å"Priceâ⬠variable value (this lets SPSS know that we want a prediction for this value and not to include the value in any other computations) (see left figure, below). . Select Analyze ? Regression ? Linearâ⬠¦ (see right figure, above). 7. Select ââ¬Å"Priceâ⬠as the dependent variable and ââ¬Å"Ageâ⬠as the independent variable (see upperleft fi gure, below). Click ââ¬Å"Statisticsâ⬠, select ââ¬Å"Estimatesâ⬠and ââ¬Å"Confidence Intervalsâ⬠for the regression coefficients, select ââ¬Å"Model fitâ⬠to obtain r2, and click ââ¬Å"Continueâ⬠(see upper-right figure, below). Click ââ¬Å"Plotsâ⬠¦Ã¢â¬ , select ââ¬Å"Normal Probability Plotâ⬠of the residuals, and click ââ¬Å"Continueâ⬠(see lower-left figure, below).Click ââ¬Å"Saveâ⬠¦Ã¢â¬ , select ââ¬Å"Unstandardizedâ⬠predicted values, select ââ¬Å"Unstandardizedâ⬠and ââ¬Å"Studentizedâ⬠residuals, select ââ¬Å"Meanâ⬠(to obtain a confidence intervalâ⬠¦output in the Data Window) and ââ¬Å"Individualâ⬠(to obtain a prediction intervalâ⬠¦output in the Data Window) at the 95% level (or whatever level the problem requires), and click ââ¬Å"Continueâ⬠(see lower-right figure, below). Click ââ¬Å"OKâ⬠. The output from this procedure is extensive and will be shown in parts in th e following answers. c. Determine the regression equation for the data. From above, the regression equation is: Price = 29160. 1942 ââ¬â (2790. 2913)(Age). 8.From within the output window, double-click on the scatterplot to enter Chart Editor mode. From the ââ¬Å"Elementsâ⬠menu, select ââ¬Å"Fit Line at Totalâ⬠. Click the close box. Now your scatterplot displays the linear regression line computed above. Graph the regression equation and the data points. d. e. Identify outliers and potential influential observations. There do not appear to be any points that lie far from the cluster of data points or far from the regression line; thus there are no possible outliers or influential observations. f. Compute and interpret the coefficient of determination, r2. The coefficient of determination is 0. 368; therefore, about 93. 68% of the variation in the price data is explained by age. The regression equation appears to be very useful for making predictions since the value of r 2 is close to 1. 9. The residuals and standardized values (as well as the predicted values, the confidence interval endpoints, and the prediction interval endpoints) can be found in the data window. 10. To create a residual plot, select Graphs ? Legacy Dialogs ? Scatter/Dotâ⬠¦ (Simple) with the residuals (RES_1) as the Y Axis variable and Age as the X Axis variable. Click ââ¬Å"Titlesâ⬠¦Ã¢â¬ to enter ââ¬Å"Residual Plotâ⬠as the title for your graph, and click ââ¬Å"Continueâ⬠.Click ââ¬Å"OKâ⬠. Double-click the resulting graph in the output window, select ââ¬Å"Optionsâ⬠? ââ¬Å"Y Axis Reference Lineâ⬠, select the ââ¬Å"Reference Lineâ⬠tab in the properties window, add position of line ââ¬Å"0â⬠, and click ââ¬Å"Applyâ⬠. Click the close box to exit the chart editor (see left plot, below). 11. To create a studentized residual plot (what the textbook calls a standardized residual plot), select Graphs ? Legacy Dialogs ? Scatter/Dotâ⬠¦ (Simple) with the studentized residuals (SRES_1) as the Y Axis variable and Age as the X Axis variable. Click ââ¬Å"Titlesâ⬠¦Ã¢â¬ to enter ââ¬Å"Studentized Residual Plotâ⬠as the title for your graph, and click ââ¬Å"Continueâ⬠.Click ââ¬Å"OKâ⬠. Double-click the resulting graph in the output window, select ââ¬Å"Optionsâ⬠? ââ¬Å"Y Axis Reference Lineâ⬠, select the ââ¬Å"Reference Lineâ⬠tab in the properties window, add position of line ââ¬Å"0â⬠, and click ââ¬Å"Applyâ⬠. If 2 and/or -2 are in the range covered by the y-axis, repeat the last steps to add a reference line at ââ¬Å"2â⬠and ââ¬Å"-2â⬠(see right plot, above); any points that are not between these lines are considered potential outliers. If 3 and/or -3 are in the range covered by the y-axis, repeat the last steps to add a reference line at ââ¬Å"3â⬠and ââ¬Å"-3â⬠; any points that are beyond these lines are considered ou tliers. 2. To assess the normality of the residuals, consult the P-P Plot from the regression output. g. Obtain the residuals and create a residual plot. Decide whether it is reasonable to consider that the assumptions for regression analysis are met by the variables in questions. The residual plot shows a random scatter of the points (independence) with a constant spread (constant variance). The studentized residual plot shows a random scatter of the points (independence) with a constant spread (constant variance) with no values beyond the à ±2 standard deviation reference lines (no outliers).The normal probability plot of the residuals shows the points close to a diagonal line; therefore, the residuals appear to be approximately normally distributed. Thus, the assumptions for regression analysis appear to be met. h. At the 10% significance level, do the data provide sufficient evidence to conclude that the slope of the population regression line is not 0 and, hence, that age is u seful as a predictor of sales price for Corvettes? Step 1: Hypotheses H 0 : ! = 0 (Age is not a useful predictor of price. ) H a : ! â⬠0 (Age is a useful predictor of price. ) Step 2: Step 3: Step 4: Significance Level ! 0. 05 Critical Value(s) and Rejection Region(s) Reject the null hypothesis if p-value ? 0. 05. Test Statistic (choose either the T-test method or the F-test methodâ⬠¦not both) T = ââ¬â10. 8873, and p-value = 0. 00000448 Step 5: Step 6: F = 118. 5330, and p-value = 0. 00000448 Conclusion Since p-value = 0. 00000448 ? 0. 05, we shall reject the null hypothesis. State conclusion in words At the ! = 0. 05 level of significance, there exists enough evidence to conclude that the slope of the population regression line is not zero and, hence, that age is useful as a predictor of price for Corvettes. . Obtain and interpret a 95% confidence interval for the slope, ? , of the population regression line that relates age to sales price for Corvettes. We are 95% co nfident that the slope of the true regression line is somewhere between ââ¬â3381. 2946 and ââ¬â2199. 2880. In other words, we are 95% confident that for every year older Corvettes get, their average price decreases somewhere between $3,381. 2946 and $2,199. 2880. j. Obtain a point estimate for the mean sales price of all 4-year-old Corvettes. The point estimate (PRE_1) is 17999. 0291 dollars ($17,999. 0291). k.Determine a 95% confidence interval for the mean sales price of all 4-year-old Corvettes. We are 95% confident that the mean sales price of all four-year-old Corvettes is somewhere between $16,958. 4604 (LMCI_1) and $19,039. 5978 (UMCI_1). l. Find the predicted sales price of Jack Smithââ¬â¢s selected 4-year-old Corvette. The predicted sales price is 17999. 0291 dollars ($17,999. 0291). m. Determine a 95% prediction interval for the sales price of Jack Smithââ¬â¢s 4-year-old Corvette. We are 95% certain that the individual sales price of Jack Smith? s Corvette wi ll be somewhere between $14,552. 9173 (LICI_1) and $21,445. 1410 (UICI_1).
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.