Answered step by step
Verified Expert Solution
Question
1 Approved Answer
https://moodle.ucl.ac.uk/mod/resource/view.php?id=4583908(day.csv) https://moodle.ucl.ac.uk/mod/resource/view.php?id=4583907?readme.txt) Exercise 3: Load the daycsv dataset from Moodle. The dataset contains information on bikesharing counts for a bikesharing company. Each observation is a
https://moodle.ucl.ac.uk/mod/resource/view.php?id=4583908(day.csv)
https://moodle.ucl.ac.uk/mod/resource/view.php?id=4583907?readme.txt)
Exercise 3: Load the daycsv dataset from Moodle. The dataset contains information on bikesharing counts for a bikesharing company. Each observation is a day, with information on how many bikes were rented out on that day. Detailed information on each variable is provided in readme_data.txt. a) (5 points) Estimate a linear regression model and predict the total number of rental bikes (on a day) based on the following explanatory variables temp, hum, weekday and weathersit. Interpret the coefficient estimate of temp (hint: check the readme for variable definitions). b) (4 points) Check the definition of the variable weathersit in the readme file. Discuss whether an alternative way of including weathersit in the linear regression model would be more appropriate to predict the number of rental bikes (on a day). c) (4 points) Discuss whether the estimated effect of temp is the true effect of weather on the total number of rental bikes. Provide at least two arguments (either for or against). d) (5 points) Perform model selection to analyze whether a regression tree would be a better model to predict the total number of rental bikes for future periods. Use a 70% training, and 30% testing split of the data, and use the Mean Squared Error (lVISE) as model fit statistics. Choose whether to focus on the in-sample or out-of-sample fit and justify this choice. Provide the R code you useStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored 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