HallOfFame: Hall of Fame Voting Data

Description Usage Format Details Source Examples

Description

Hall of Fame table. This is comprised of the voting results for all candidates nominated for the Baseball Hall of Fame.

Usage

1

Format

A data frame with 4054 observations on the following 8 variables.

playerID

Player ID code

yearID

Year of ballot

votedBy

Method by which player was voted upon. See Details

ballots

Total ballots cast in that year

needed

Number of votes needed for selection in that year

votes

Total votes received

inducted

Whether player was inducted by that vote or not (Y or N)

category

Category of candidate; a factor with levels Manager Pioneer/Executive Player Umpire

needed_note

Explanation of qualifiers for special elections

Details

This table links to the Master table via the playerID.

votedBy: Most Hall of Fame inductees have been elected by the Baseball Writers Association of America (BBWAA). Rules for election are described in http://en.wikipedia.org/wiki/National_Baseball_Hall_of_Fame_and_Museum#Selection_process.

Source

Lahman, S. (2014) Lahman's Baseball Database, 1871-2013, 2014 version, http://baseball1.com/statistics/

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
## Some examples for  Hall of Fame induction data

data('HallOfFame')
require('plyr')          ## extensive use of plyr for data manipulation 
require('ggplot2')

############################################################
## Some simple queries

# What are the different types of votedBy?
table(HallOfFame$votedBy)

# What was the first year of Hall of Fame elections?
sort(unique(HallOfFame$yearID))[1]
# Who comprised the original class?
subset(HallOfFame, yearID == 1936 & inducted == 'Y')

# Result of a player's last year on the BBWAA ballot
# Restrict to players voted by BBWAA:
HOFplayers <- subset(HallOfFame, votedBy == 'BBWAA' & category == 'Player')


# Function to calculate number of years as HOF candidate, last pct vote, etc.
# for a given player
HOFun <- function(d) {
    nyears <- nrow(d)
    fy <- d[nyears, ]
    lastPct <- with(fy, 100 * round(votes/ballots, 3))
    data.frame(playerID = fy$playerID, nyears, induct = fy$inducted,
               lastPct, lastYear = fy$yearID)
}

playerOutcomesHOF <- ddply(HOFplayers, .(playerID), HOFun)


############################################################
# How many voting years until election?
inducted <- subset(playerOutcomesHOF,induct == 'Y')
table(inducted$nyears)
barplot(table(inducted$nyears), main="Number of voting years until election",
		ylab="Number of players", xlab="Years")

# What is the form of this distribution?
# Note that this question requires a zero-truncated distribution, because nyears==0 cannot occur
require('vcd')
goodfit(inducted$nyears)
plot(goodfit(inducted$nyears), xlab='Number of years',
	main="Poissonness plot of number of years voting until election")
Ord_plot(table(inducted$nyears), xlab='Number of years')



# First ballot inductees:
subset(playerOutcomesHOF, nyears == 1L & induct == 'Y')

# Who took at least ten years on the ballot before induction?
# (Doesn't include Bert Blyleven, who was inducted in 2011.)
subset(playerOutcomesHOF, nyears >= 10L & induct == 'Y')

############################################################
## Plots of voting percentages over time for the borderline
## HOF candidates, according to the BBWAA:

# (1) Set up the data:
longTimers <- as.character(unlist(subset(playerOutcomesHOF,
                                         nyears >= 10, select = 'playerID')))
HOFlt <- subset(HallOfFame, playerID %in% longTimers & votedBy == 'BBWAA')
HOFlt <- ddply(HOFlt, .(playerID), mutate,
                  elected = ifelse(any(inducted == 'Y'),"Elected", "Not elected"),
                  pct = 100 * round(votes/ballots, 3))

# Plot the voting profiles:
ggplot(HOFlt, aes(x = yearID, y = pct,
                  group = playerID)) +
    ggtitle("Profiles of voting percentage for long-time HOF candidates") +
    geom_line() +
    geom_hline(yintercept = 75, col = 'red') +
    labs(list(x = "Year", y = "Percentage of votes")) +
    facet_wrap(~ elected, ncol = 1)

# Note: All but one of the players whose maximum voting percentage
# was over 60% and was not elected by the BBWAA has eventually been inducted
# into the HOF. Red Ruffing was elected in a 1967 runoff election while
# the others have been voted in by the Veterans Committee. The lone
# exception is Gil Hodges; his profile is the one that flatlines around 60%
# for several years in the late 70s and early 80s.

Example output

Loading required package: plyr
Loading required package: ggplot2

           BBWAA       Centennial     Final Ballot     Negro League 
            3723                6               21               26 
 Nominating Vote       Old Timers          Run Off Special Election 
              76               30               81                2 
        Veterans 
             191 
[1] 1936
   playerID yearID votedBy ballots needed votes inducted category needed_note
1  cobbty01   1936   BBWAA     226    170   222        Y   Player        <NA>
2  ruthba01   1936   BBWAA     226    170   215        Y   Player        <NA>
3 wagneho01   1936   BBWAA     226    170   215        Y   Player        <NA>
4 mathech01   1936   BBWAA     226    170   205        Y   Player        <NA>
5 johnswa01   1936   BBWAA     226    170   189        Y   Player        <NA>

 1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 
51 10  9  8  8  4  3  4  6  4  3  1  4  1  2 
Loading required package: vcd
Loading required package: grid

Observed and fitted values for poisson distribution
with parameters estimated by `ML' 

 count observed       fitted pearson residual
     0        0  1.985635198      -1.40912569
     1       51  8.110814960      15.05967319
     2       10 16.565308520      -1.61307803
     3        9 22.555024594      -2.85416225
     4        8 23.032885285      -3.13233477
     5        8 18.816696114      -2.49357792
     6        4 12.810236620      -2.46155190
     7        3  7.475222822      -1.63682629
     8        4  3.816798093       0.09377356
     9        6  1.732294427       3.24252696
    10        4  0.707598232       3.91398770
    11        3  0.262759898       5.33990280
    12        1  0.089442282       3.04464068
    13        4  0.028103768      23.69275806
    14        1  0.008199768      10.95275653
    15        2  0.002232931      36.58614498
      playerID nyears induct lastPct lastYear
1    aaronha01      1      Y    97.8     1982
43   bankser01      1      Y    83.8     1977
62   benchjo01      1      Y    96.4     1989
90   boggswa01      1      Y    91.9     2005
109  brettge01      1      Y    98.2     1999
114  brocklo01      1      Y    79.7     1985
157  carewro01      1      Y    90.5     1991
159  carltst01      1      Y    95.6     1994
195   cobbty01      1      Y    98.2     1936
291  eckerde01      1      Y    83.2     2004
314  fellebo01      1      Y    93.8     1962
365  gibsobo01      1      Y    84.0     1981
371  glavito02      1      Y    91.9     2014
394  griffke02      1      Y    99.3     2016
417  gwynnto01      1      Y    97.6     2007
445  henderi01      1      Y    94.8     2009
495  jacksre01      1      Y    93.6     1993
508  johnsra05      1      Y    97.3     2015
509  johnswa01      1      Y    83.6     1936
527  kalinal01      1      Y    88.3     1980
560  koufasa01      1      Y    86.9     1972
621  maddugr01      1      Y    97.2     2014
627  mantlmi01      1      Y    88.2     1974
641  martipe02      1      Y    91.1     2015
643  mathech01      1      Y    90.7     1936
655   mayswi01      1      Y    94.7     1979
661  mccovwi01      1      Y    81.4     1986
703  molitpa01      1      Y    85.2     2004
715  morgajo02      1      Y    81.8     1990
729  murraed02      1      Y    85.3     2003
732  musiast01      1      Y    93.2     1969
770  palmeji01      1      Y    92.6     1990
811  puckeki01      1      Y    82.1     2001
847  ripkeca01      1      Y    98.5     2007
855  robinbr01      1      Y    92.0     1983
856  robinfr02      1      Y    89.2     1982
857  robinja02      1      Y    77.5     1962
858  rodriiv01      1      Y    76.0     2017
878   ruthba01      1      Y    95.1     1936
880   ryanno01      1      Y    98.8     1999
902  schmimi01      1      Y    96.5     1995
912  seaveto01      1      Y    98.8     1992
946  smithoz01      1      Y    91.7     2002
949  smoltjo01      1      Y    82.9     2015
966  stargwi01      1      Y    82.4     1988
1006 thomafr04      1      Y    83.7     2014
1053 wagneho01      1      Y    95.1     1936
1096 willite01      1      Y    93.4     1966
1102 winfida01      1      Y    84.5     2001
1116 yastrca01      1      Y    94.6     1989
1124 yountro01      1      Y    77.5     1999
      playerID nyears induct lastPct lastYear
86   blylebe01     14      Y    79.7     2011
100  boudrlo01     10      Y    77.3     1970
223  cronijo01     10      Y    78.8     1956
279  drysddo01     10      Y    78.4     1984
436  hartnga01     11      Y    77.7     1955
441  heilmha01     11      Y    86.8     1952
546  kinerra01     13      Y    75.4     1975
589  lemonbo01     12      Y    78.6     1976
629  maranra01     13      Y    82.9     1954
817  raineti01     10      Y    86.0     2017
839   riceji01     15      Y    76.4     2009
950  snidedu01     11      Y    86.5     1980
989  suttebr01     13      Y    76.9     2006
1002 terrybi01     13      Y    77.4     1954
1037 vanceda01     15      Y    81.7     1955

Lahman documentation built on May 2, 2019, 5:25 p.m.