Skip to contents

Fielding table

Usage

data(Fielding)

Format

A data frame with 151507 observations on the following 18 variables.

playerID

Player ID code

yearID

Year

stint

player's stint (order of appearances within a season)

teamID

Team; a factor

lgID

League; a factor with levels AA AL FL NL PL UA

POS

Position

G

Games

GS

Games Started

InnOuts

Time played in the field expressed as outs

PO

Putouts

A

Assists

E

Errors

DP

Double Plays

PB

Passed Balls (by catchers)

WP

Wild Pitches (by catchers)

SB

Opponent Stolen Bases (by catchers)

CS

Opponents Caught Stealing (by catchers)

ZR

Zone Rating

Source

Lahman, S. (2024) Lahman's Baseball Database, 1871-2023, 2024 version, http://www.seanlahman.com/

Examples

data(Fielding)
# Basic fielding data

require("dplyr")


# Roberto Clemente's fielding profile
# pitching and catching related data removed
# subset(Fielding, playerID == "clemero01")[, 1:13]
Fielding %>% 
   filter(playerID == "clemero01") %>%
   select(1:13)
#>     playerID yearID stint teamID lgID POS   G  GS InnOuts  PO  A  E DP
#> 1  clemero01   1955     1    PIT   NL  OF 118 107    2892 253 18  6  5
#> 2  clemero01   1956     1    PIT   NL  2B   2   0      18   1  1  1  0
#> 3  clemero01   1956     1    PIT   NL  3B   1   0       6   0  2  1  0
#> 4  clemero01   1956     1    PIT   NL  OF 139 130    3499 274 17 13  2
#> 5  clemero01   1957     1    PIT   NL  OF 109 107    2836 272  9  6  1
#> 6  clemero01   1958     1    PIT   NL  OF 135 129    3452 312 22  6  3
#> 7  clemero01   1959     1    PIT   NL  OF 104 102    2700 229 10 13  1
#> 8  clemero01   1960     1    PIT   NL  OF 142 140    3767 246 19  8  2
#> 9  clemero01   1961     1    PIT   NL  OF 144 142    3723 256 27  9  5
#> 10 clemero01   1962     1    PIT   NL  OF 142 138    3686 269 19  8  1
#> 11 clemero01   1963     1    PIT   NL  OF 151 148    3943 239 11 11  2
#> 12 clemero01   1964     1    PIT   NL  OF 154 154    4085 289 13 10  2
#> 13 clemero01   1965     1    PIT   NL  OF 145 143    3810 288 16 10  1
#> 14 clemero01   1966     1    PIT   NL  OF 154 153    4147 318 17 12  3
#> 15 clemero01   1967     1    PIT   NL  OF 145 141    3751 273 17  9  4
#> 16 clemero01   1968     1    PIT   NL  OF 131 128    3477 297  9  5  1
#> 17 clemero01   1969     1    PIT   NL  OF 135 128    3372 226 14  5  1
#> 18 clemero01   1970     1    PIT   NL  OF 104 102    2703 189 12  7  2
#> 19 clemero01   1971     1    PIT   NL  OF 124 120    3243 267 11  2  4
#> 20 clemero01   1972     1    PIT   NL  OF  94  88    2436 199  5  0  2
   
# Yadier Molina's fielding profile
# PB, WP, SP and CS apply to catchers
Fielding %>% 
  subset(playerID == "molinya01") %>%
  select(-WP, -ZR)
#>        playerID yearID stint teamID lgID POS   G  GS InnOuts   PO  A  E DP PB
#> 93856 molinya01   2004     1    SLN   NL   C  51  39    1032  256 16  2  1  4
#> 93857 molinya01   2005     1    SLN   NL  1B   1   0       3    0  0  0  0 NA
#> 93858 molinya01   2005     1    SLN   NL   C 114 111    2878  684 66  7  4  8
#> 93859 molinya01   2006     1    SLN   NL  1B   4   0      15    5  0  1  1 NA
#> 93860 molinya01   2006     1    SLN   NL   C 127 118    3112  734 79  4  6  7
#> 93861 molinya01   2007     1    SLN   NL  1B   1   0       3    1  0  0  0 NA
#> 93862 molinya01   2007     1    SLN   NL   C 107 101    2584  582 63  6  8  7
#> 93863 molinya01   2008     1    SLN   NL  1B   2   1      33   13  3  0  1 NA
#> 93864 molinya01   2008     1    SLN   NL   C 119 114    3006  653 70 10  7  5
#> 93865 molinya01   2009     1    SLN   NL  1B   6   0      30   10  1  0  2 NA
#> 93866 molinya01   2009     1    SLN   NL   C 138 136    3530  884 82  5  6  4
#> 93867 molinya01   2010     1    SLN   NL  1B   7   0      21    7  0  0  2 NA
#> 93868 molinya01   2010     1    SLN   NL   C 135 130    3414  895 79  5 10  7
#> 93869 molinya01   2011     1    SLN   NL  1B   2   0       6    3  0  1  0 NA
#> 93870 molinya01   2011     1    SLN   NL   C 137 132    3450  857 67  5  5  6
#> 93871 molinya01   2012     1    SLN   NL  1B   3   0      27   11  2  0  0 NA
#> 93872 molinya01   2012     1    SLN   NL   C 136 133    3484  962 88  3 12  6
#> 93873 molinya01   2013     1    SLN   NL  1B   5   2      54   17  1  0  1 NA
#> 93874 molinya01   2013     1    SLN   NL   C 131 129    3346  976 63  4 11  3
#> 93875 molinya01   2014     1    SLN   NL  1B   1   1      27   10  1  0  0 NA
#> 93876 molinya01   2014     1    SLN   NL   C 107 106    2795  810 56  2 10  3
#> 93877 molinya01   2015     1    SLN   NL   C 134 131    3449 1064 56  7  9  4
#> 93878 molinya01   2016     1    SLN   NL  1B   2   1      21   10  1  0  0 NA
#> 93879 molinya01   2016     1    SLN   NL   C 146 142    3655 1113 60  2  5  8
#> 93880 molinya01   2017     1    SLN   NL  1B   1   0       6    4  0  0  0 NA
#> 93881 molinya01   2017     1    SLN   NL   C 133 133    3377 1082 55  7 13  6
#> 93882 molinya01   2018     1    SLN   NL  1B   5   0      36    9  2  1  3 NA
#> 93883 molinya01   2018     1    SLN   NL   C 121 120    3053  966 42  2  8  4
#> 93884 molinya01   2019     1    SLN   NL  1B   4   0      24    6  0  0  1 NA
#> 93885 molinya01   2019     1    SLN   NL  3B   1   0       3    0  0  0  0 NA
#> 93886 molinya01   2019     1    SLN   NL   C 111 108    2818  916 30  1  5  4
#> 93887 molinya01   2020     1    SLN   NL  1B   2   0      15    3  0  0  0 NA
#> 93888 molinya01   2020     1    SLN   NL   C  42  42    1012  307 16  5  1  3
#> 93889 molinya01   2021     1    SLN   NL  1B   1   0       9    1  1  0  0 NA
#> 93890 molinya01   2021     1    SLN   NL   C 118 118    3004  869 49  3 10  6
#> 93891 molinya01   2022     1    SLN   NL  1B   1   0       3    0  0  0  0 NA
#> 93892 molinya01   2022     1    SLN   NL   C  77  71    1885  512 25  3  6  1
#> 93893 molinya01   2022     1    SLN   NL   P   2   0       6    0  0  0  0 NA
#>       SB CS
#> 93856  9  8
#> 93857 NA NA
#> 93858 14 25
#> 93859 NA NA
#> 93860 37 29
#> 93861 NA NA
#> 93862 23 27
#> 93863 NA NA
#> 93864 34 18
#> 93865 NA NA
#> 93866 32 22
#> 93867 NA NA
#> 93868 35 33
#> 93869 NA NA
#> 93870 46 19
#> 93871 NA NA
#> 93872 38 35
#> 93873 NA NA
#> 93874 26 20
#> 93875 NA NA
#> 93876 23 21
#> 93877 37 26
#> 93878 NA NA
#> 93879 67 18
#> 93880 NA NA
#> 93881 43 24
#> 93882 NA NA
#> 93883 27 12
#> 93884 NA NA
#> 93885 NA NA
#> 93886 22  8
#> 93887 NA NA
#> 93888  6  5
#> 93889 NA NA
#> 93890 26 18
#> 93891 NA NA
#> 93892 20 13
#> 93893 NA NA

# Pedro Martinez's fielding profile
Fielding %>% subset(playerID == "martipe02")
#>        playerID yearID stint teamID lgID POS  G GS InnOuts PO  A E DP PB WP SB
#> 85473 martipe02   1992     1    LAN   NL   P  2  1      24  0  0 0  0 NA NA NA
#> 85474 martipe02   1993     1    LAN   NL   P 65  2     321  4  4 0  1 NA NA NA
#> 85475 martipe02   1994     1    MON   NL   P 24 23     434  9 15 4  0 NA NA NA
#> 85476 martipe02   1995     1    MON   NL   P 30 30     584 14 23 2  0 NA NA NA
#> 85477 martipe02   1996     1    MON   NL   P 33 33     650 11 17 3  1 NA NA NA
#> 85478 martipe02   1997     1    MON   NL   P 31 31     724  7 31 1  1 NA NA NA
#> 85479 martipe02   1998     1    BOS   AL   P 33 33     701 11 18 4  3 NA NA NA
#> 85480 martipe02   1999     1    BOS   AL   P 31 29     640 13 15 1  0 NA NA NA
#> 85481 martipe02   2000     1    BOS   AL   P 29 29     651 14 28 0  2 NA NA NA
#> 85482 martipe02   2001     1    BOS   AL   P 18 18     350  5  5 0  0 NA NA NA
#> 85483 martipe02   2002     1    BOS   AL   P 30 30     598 16 16 2  1 NA NA NA
#> 85484 martipe02   2003     1    BOS   AL   P 29 29     560 14 20 0  0 NA NA NA
#> 85485 martipe02   2004     1    BOS   AL   P 33 33     651 16 16 1  0 NA NA NA
#> 85486 martipe02   2005     1    NYN   NL   P 31 31     651  6 19 0  0 NA NA NA
#> 85487 martipe02   2006     1    NYN   NL   P 23 23     398  7 13 5  0 NA NA NA
#> 85488 martipe02   2007     1    NYN   NL   P  5  5      84  1  0 0  0 NA NA NA
#> 85489 martipe02   2008     1    NYN   NL   P 20 20     327  6 17 0  1 NA NA NA
#> 85490 martipe02   2009     1    PHI   NL   P  9  9     134  1  6 0  1 NA NA NA
#>       CS ZR
#> 85473 NA NA
#> 85474 NA NA
#> 85475 NA NA
#> 85476 NA NA
#> 85477 NA NA
#> 85478 NA NA
#> 85479 NA NA
#> 85480 NA NA
#> 85481 NA NA
#> 85482 NA NA
#> 85483 NA NA
#> 85484 NA NA
#> 85485 NA NA
#> 85486 NA NA
#> 85487 NA NA
#> 85488 NA NA
#> 85489 NA NA
#> 85490 NA NA

# Table of games played by Pete Rose at different positions
with(subset(Fielding, playerID == "rosepe01"), xtabs(G ~ POS))
#> POS
#>   1B   2B   3B   OF 
#>  939  628  634 1327 

# Career total G/PO/A/E/DP for Luis Aparicio
Fielding %>%
    filter(playerID == "aparilu01") %>% 
    select(G, PO, A, E, DP) %>%
    summarise_each(funs(sum))
#> Warning: `summarise_each()` was deprecated in dplyr 0.7.0.
#>  Please use `across()` instead.
#> Warning: `funs()` was deprecated in dplyr 0.8.0.
#>  Please use a list of either functions or lambdas:
#> 
#> # Simple named list: list(mean = mean, median = median)
#> 
#> # Auto named with `tibble::lst()`: tibble::lst(mean, median)
#> 
#> # Using lambdas list(~ mean(., trim = .2), ~ median(., na.rm = TRUE))
#>      G   PO    A   E   DP
#> 1 2583 4548 8016 366 1553


# Top ten 2B/SS in turning DPs
Fielding %>%
    subset(POS %in% c("2B", "SS")) %>%
    group_by(playerID) %>%
    summarise(TDP = sum(DP, na.rm = TRUE)) %>%
    arrange(desc(TDP)) %>%
    head(., 10)
#> # A tibble: 10 × 2
#>    playerID    TDP
#>    <chr>     <int>
#>  1 vizquom01  1775
#>  2 mazerbi01  1706
#>  3 foxne01    1619
#>  4 smithoz01  1590
#>  5 ripkeca01  1565
#>  6 aparilu01  1553
#>  7 randowi01  1547
#>  8 whitalo01  1527
#>  9 doerrbo01  1507
#> 10 morgajo02  1505

# League average fielding statistics, 1961-present
Fielding %>% 
   filter(yearID >= 1961 & POS != "DH") %>%
   select(yearID, lgID, POS, InnOuts, PO, A, E) %>%
   group_by(yearID, lgID) %>%
   summarise_at(vars(InnOuts, PO, A, E), funs(sum), na.rm = TRUE) %>%
   mutate(fpct = round( (PO + A)/(PO + A + E), 3), 
          OPE = round(InnOuts/E, 3))
#> Warning: `funs()` was deprecated in dplyr 0.8.0.
#>  Please use a list of either functions or lambdas:
#> 
#> # Simple named list: list(mean = mean, median = median)
#> 
#> # Auto named with `tibble::lst()`: tibble::lst(mean, median)
#> 
#> # Using lambdas list(~ mean(., trim = .2), ~ median(., na.rm = TRUE))
#> # A tibble: 126 × 8
#> # Groups:   yearID [63]
#>    yearID lgID  InnOuts    PO     A     E  fpct   OPE
#>     <int> <fct>   <int> <int> <int> <int> <dbl> <dbl>
#>  1   1961 AL     389523 43213 17237  1506 0.976  259.
#>  2   1961 NL     297720 33080 13728  1167 0.976  255.
#>  3   1962 AL     391878 43449 17138  1364 0.978  287.
#>  4   1962 NL     391206 43470 17832  1555 0.975  252.
#>  5   1963 AL     392877 43589 16998  1347 0.978  292.
#>  6   1963 NL     392946 43661 17681  1577 0.975  249.
#>  7   1964 AL     394593 43774 17130  1261 0.98   313.
#>  8   1964 NL     392094 43566 17933  1586 0.975  247.
#>  9   1965 AL     392562 43546 17231  1359 0.978  289.
#> 10   1965 NL     395384 43932 18008  1486 0.977  266.
#> # ℹ 116 more rows