10.07.2015 Views

Using R for Introductory Statistics : John Verzani

Using R for Introductory Statistics : John Verzani

Using R for Introductory Statistics : John Verzani

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Using</strong> R <strong>for</strong> introductory statistics 27010.2 For the data set MLBattend (<strong>Using</strong>R) concerning major league baseballattendance, fit a linear model of attendance modeled by wins. What is the predictedincrease in attendance if a team that won 80 games last year wins 90 this year?10.3 People often predict children’s future height by using their 2-year-old height. Acommon rule is to double the height. Table 10.2 contains data <strong>for</strong> eight people’s heightsas 2-year-olds and as adults. <strong>Using</strong> the data, what is the predicted adult height <strong>for</strong> a 2-year-old who is 33 inches tall?Table 10.2 Height as two-year old and as anadultAge 2 (in.) 39 30 32 34 35 36 36 30Adult (in.) 71 63 63 67 68 68 70 6410.4 The galton on (<strong>Using</strong>R) data set contains data collected by Francis Galton in1885 concerning the influence a parent’s height has on a child’s height. Fit a linear model<strong>for</strong> a child’s height modeled by his parent’s height. Make a scatterplot with a regressionline. (Is this dataset a good candidate <strong>for</strong> using jitter () ?) What is the value of andwhy is this of interest?10.5 Formulas (10.1), (10.2), and the prediction line equation can be rewritten in termsof the correlation coefficient, r, asThus the five summary numbers: the two means, the standard deviations, and thecorrelation coefficient are fundamental <strong>for</strong> regression analysis.This is interpreted as follows. Scaled differences of from the mean are less thanthe scaled differences of x i from as |r|≤1. That is, “regression” toward the mean, asunusually large differences from the mean are lessened in their prediction <strong>for</strong> y.For the data set galton on (<strong>Using</strong>R) use scale () on the variables parent and child, andthen model the height of the child by the height of the parent. What are the estimates <strong>for</strong> rand β 1 ?10.2 Statistical inference <strong>for</strong> simple linear regressionIf we are convinced that the simple regression model is appropriate <strong>for</strong> our data, thenstatistical inferences can be made about the unknown parameters. To assess whether thesimple regression model is appropriate <strong>for</strong> the data we use a graphical approach.10.2.1 Testing the model assumptionsThe simple linear regression model places assumptions on the data set that we shouldverify be<strong>for</strong>e proceeding with any statistical inference. In particular, the linear model

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!