Question: Using R code please answer the following question. Thank you Linear regression in R: (print out your R code and results) The data set whiteside

Using R code please answer the following question. Thank you

Using R code please answer the following question. Thank you Linear regression

Linear regression in R: (print out your R code and results) The data set whiteside is available after loading the MASS package by calling li- brary (MASS). For detailed description of this data set, run ?whitwside. Complete the following questions: (a) From whiteside, select a subset called whitesideBefore which only contains obser vations whose Insul = Before and has two columns Temp and Gas. (b) Use the plot function to produce a scatterplot of whitesideBefore. Put Temp on x-axis and Gas on y-axis. From the plot, which correlation type is between Temp and Gas? Does the linear model looks suitable for this data set? (c) Call function Im to fit a simple linear model for whitesideBefore. Set Gas as response variable and Temp as predictor. Assign the fitting result to some name, say whiteside.Im, for later usage. (d) Report LSE of the intercept and slope coefficients. Also report all the fitted values and residulas

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!