Answered step by step
Verified Expert Solution
Question
1 Approved Answer
oas Note that the same variable can play different roles! Take a quick look at the variable 'cylinders', try to use this variable in the
oas Note that the same variable can play different roles! Take a quick look at the variable 'cylinders', try to use this variable in the following analyses wisely. We all agree that larger number of cylinder will lower mpg. However, we can interpret \"cylinders' as either a continuous [numeric] variable or a categorical variable. i. Fit a model, that treats 'cylinders' as a continuous ,r'numeric variable: "lm[mpg .... horsepower + cylinders. ISLRsAutoT. Is 'cylinders' signicant at the lll level? What effect does 'cylinders' play in this model? ii. Fit a model that treats \"cylinders" as a categorical;r factor variable: 'lm[mpg w horsepower + as.factor[cylinders], ISLE: :Auto]". Is "Cylinders' signicant at the .31 level? 1What is the effect of 'cylinders' in this model? iii. 1What are the fundamental differences bemeen treating \"cylinders\" as a numeric or a factor? Use \"anovalCtl. tEI' to help gauge the effect. Explain their difference
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started