beanumber / baseball_R

Companion to Analyzing Baseball Data with R, 2nd edition
95 stars 62 forks source link

fix errata from 1st edition #1

Closed beanumber closed 6 years ago

beanumber commented 6 years ago

It contains bibliographical information on every player and manager who have appeared at the Major League Baseball level and of all people who have been inducted in the Baseball Hall of Fame.

Table 1.4 displays statistics from the data file Pitching.csv for the seasons where Ruth was a pitcher.

The following questions can be answered with Lahman�s database.

Replace "per games�" to "per game�" (two times).

This table displays team statistics \footnote{Some of the less important statistics, such as Catcher Interference, have been omitted in Table \ref{tab:gamelog}} as well as the players' identities and fielding positions for the home team; similar statistics and player information are available for the visitor team.

with this paragraph:

This table displays team statistics \footnote{Some other team statistics, such as Stolen Bases and Caught Stealings, omitted in Table \ref{tab:gamelog}, are reported in Game log files.} as well as the players' identities and fielding positions for the home team; similar statistics and player information are available for the visitor team.

rstudio.org should be rstudio.com

Change "features of R" to "feature of R"

"ball in play�" should be "balls in play�"

Change "350 Wins" to "350-Wins� (three times)

hof <- read.csv("hofbatting.csv") hof$MidCareer <- with(hof, (From + To) / 2) hof$Era <- cut(hof$MidCareer, breaks = c(1800, 1900, 1919, 1941, 1960, 1976, 1993, 2050), labels = c("19th Century", "Dead Ball", "Lively Ball", "Integration", "Expansion", "Free Agency", "Long Ball"))

"dotplot�" should be "dot plot�"

In many places, "runs expectancy" should be replaced with "run expectancy". Similarly replace "runs value" with "run value" throughout this chapter.

Replace "Dotplot�" with "Stripchart�".

Replace "group argument" with "groups argument"

Replace "appearance of the line" with "appearance of the line,"

Replace "pitching statistics as from his MLB" to "pitching statistics from his MLB"

Replace "In addition, one adds the difference between the fielding position values of the two players." with "In addition, one subtracts the absolute value of the difference between the fielding position values of the two players. ".

Replace "field.csv�" with "fields.csv"