# Reading the data into R: my.datafile <- tempfile() cat(file=my.datafile, \" 71 15 74 19 ...

70.2K

Verified Solution

Question

Statistics

# Reading the data into R:my.datafile <- tempfile()cat(file=my.datafile, \" 71 15 74 19 70 11 71 15 69 12 73 17 72 15 75 19 72 16 74 18 71 13 72 15 73 17 72 16 71 15 75 20 71 15 75 19 78 22 79 23 72 16 75 20 76 21 74 19 70 13 \", sep=\" \")options(scipen=999) # suppressing scientific notationsimpbasketball <- read.table(my.datafile, header=FALSE, col.names=c(\"height\", \"goals\")) 

COMPUTER CALCULATIONS:

I need to know how to code in R for the solutions, notby hand.

2. Look at the data in Table 7.18 on page 368 of the textbook.These data are also

given in the SAS code labeled “SAS_basketball_goal_data” and Rcode labeled basketball goal data .

The dependent variable is goals and the independent variable isheight of basketball players.

Complete a SAS /R program and answer the following questionsabout the data set:

(a) Does a scatter plot indicate a linear relationship betweenthe two variables?

Is there anything disconcerting about the scatter plot?Explain.

(b) Fit the least-squares regression line (using SAS / R) andinterpret the estimated slope

in the context of this data set. Does it make sense to interpretthe estimated intercept? Explain.

(c) For these data, what is the unbiased estimate of the errorvariance? (Give a number.)

(d) Using the SAS / R output, test the hypothesis that the trueslope of the regression line

is zero (as opposed to nonzero). State the appropriate null andalternative hypotheses,

give the value of the test statistic and give the appropriateP-value. (Use significance

level of 0.05.) Explain what this means in terms of therelationship between the two

variables.

(e) Using SAS / R, find a 95% confidence interval for the meanbasketball goal for

a player with a height of 77 inches. In addition find a 95%prediction interval for

basketball goal for a player with a height of 77 inches.

Answer & Explanation Solved by verified expert
3.5 Ratings (513 Votes)
aheight height1 71 74 70 71 69 73 72 75 72 74 71 72 73 72 71 75 71 75 78 79 7275 76 74 70goals goals1 15 19 11 15 12 17 15 19 16 18 13 15 17 16 15 20 15 19 22 23 1620 21 19 13 plotheightgoalsYes the scatter plot indicates linear relationshipNo there is nothing disconcerting about this scatter    See Answer
Get Answers to Unlimited Questions

Join us to gain access to millions of questions and expert answers. Enjoy exclusive benefits tailored just for you!

Membership Benefits:
  • Unlimited Question Access with detailed Answers
  • Zin AI - 3 Million Words
  • 10 Dall-E 3 Images
  • 20 Plot Generations
  • Conversation with Dialogue Memory
  • No Ads, Ever!
  • Access to Our Best AI Platform: Flex AI - Your personal assistant for all your inquiries!
Become a Member

Other questions asked by students