You must turn in a knitted file to Gradescope from a Quarto Markdown file in order to receive credit. Be sure to “associate” questions appropriately on Gradescope. As a reminder, late work is not accepted outside of the 24-hour grace period for homework assignments.
The Quarto template for this assignment may be found in the repository at the following link: https://classroom.github.com/a/4yjSeHXP
Baseball is one of the most popular sports in the US. In baseball, two teams take turns on offense and defense, where the offensive team aims to earn points by primarily by running bases and the defensive team aims to stop them. When a team is on the offensive, their players take turns at bat, whereby they aim to hit the baseball in order to give their team’s players the opportunity to score points.
One (not great, but it's something) way in which teams might measure the strength of a player is the batting average (AVG), which is given by the number of successful hits divided by the number of times a player had an opportunity at bat. In recent years, the league-wide average is around 0.250 (i.e., successfully hitting 25%) [3]. A batting average greater than 0.300 is considered excellent. Note that the batting averages here are reported as percentages out of 100, so each additional unit increase is an absolute percentage point increase in batting average.
Today's data are pre-COVID baseball statistics that contain salary information (salary), the number of games that player has ever played (G), batting average (AVG), whether the player is an All-Star (allstar), whether they bat left-handed, right-handed, or with both hands (bats), the age at which they debuted in the Major Leagues (ageDebut), among other variables.
This week’s homework focuses on statistical inference and linear regression models with a multiple predictors, including categorical ones.
Important: Some of your grade on this assignment will also be based on meaningful commit descriptions. For the purposes of this assignment, you must make at least two meaningful commits/pushes with an appropriate description. As well, don’t forget to change the name in the Quarto template.