- Use Linear Regression to find the variables that can predict MPG
- Build a prediction model using those variables
- Create a shiny app that enables users to input those variables in order to predict MPG
- Include the mtcars table so that users can compare their result to the real data
sort(cor(mtcars)[1,])
## wt cyl disp hp carb qsec
## -0.8676594 -0.8521620 -0.8475514 -0.7761684 -0.5509251 0.4186840
## gear am vs drat mpg
## 0.4802848 0.5998324 0.6640389 0.6811719 1.0000000
This correlation shows that wt, hp, am, cyl and disp are all highly correlated with mpg