Skip to contents

MLB Game Status Codes

Usage

mlb_game_status_codes()

Value

Returns a tibble with the following columns

col_nametypesdescription
abstract_game_statecharacterAbstract game state grouping (e.g. 'Preview', 'Live', 'Final').
coded_game_statecharacterSingle-letter coded game state (e.g. 'S', 'P', 'I', 'F').
detailed_statecharacterDetailed status description (e.g. 'Scheduled', 'Pre-Game', 'In Progress').
status_codecharacterStatus code identifier (e.g. 'S', 'P', 'I', 'F').
reasoncharacterReason text for the status when applicable (e.g. delay/postponement).
abstract_game_codecharacterSingle-letter abstract game code (e.g. 'P', 'L', 'F').

Examples

# \donttest{
  try(mlb_game_status_codes())
#> ── MLB Game Status Codes data from MLB.com ────────── baseballr 2.0.0 ──
#>  Data updated: 2026-06-12 14:09:33 UTC
#> # A tibble: 209 × 6
#>    abstract_game_state coded_game_state detailed_state       status_code
#>    <chr>               <chr>            <chr>                <chr>      
#>  1 Preview             S                Scheduled            S          
#>  2 Preview             P                Pre-Game             P          
#>  3 Live                P                Warmup               PW         
#>  4 Preview             P                Delayed Start: Rain  PR         
#>  5 Preview             P                Delayed Start: Snow  PS         
#>  6 Preview             P                Delayed Start: Wet … PG         
#>  7 Preview             P                Delayed Start: Venue PV         
#>  8 Preview             P                Delayed Start: Fog   PF         
#>  9 Preview             P                Delayed Start: Cold  PC         
#> 10 Preview             P                Delayed Start: Air … PD         
#> # ℹ 199 more rows
#> # ℹ 2 more variables: abstract_game_code <chr>, reason <chr>
# }