Skip to contents

Returns a data frame with field names and descriptions for leaderboard or hole-by-hole data.

Usage

pga_field_descriptions(data_type = c("leaderboard", "holes"))

Arguments

data_type

Character. Either "leaderboard" or "holes".

Value

A tibble with field and description columns.

Examples

pga_field_descriptions("leaderboard")
#> # A tibble: 9 × 2
#>   field           description                                   
#>   <chr>           <chr>                                         
#> 1 position        Final tournament standing                     
#> 2 player_id       ESPN athlete ID                               
#> 3 player_name     Player display name                           
#> 4 total_score     Total strokes across completed rounds         
#> 5 score_to_par    Score relative to par (e.g., '-11', 'E', '+5')
#> 6 status          Player status (live API only)                 
#> 7 tournament_id   ESPN event ID                                 
#> 8 tournament_name Name of the tournament                        
#> 9 year            Tournament year                               
pga_field_descriptions("holes")
#> # A tibble: 15 × 2
#>    field           description                                                  
#>    <chr>           <chr>                                                        
#>  1 player_id       ESPN athlete ID                                              
#>  2 player_name     Player display name                                          
#>  3 position        Final leaderboard standing                                   
#>  4 tournament_id   ESPN event ID                                                
#>  5 tournament_name Name of the tournament                                       
#>  6 round           Round number (5 = playoff)                                   
#>  7 hole            Hole number (1-18)                                           
#>  8 par             Par for the hole                                             
#>  9 score           Strokes taken on the hole                                    
#> 10 score_type      Score classification (EAGLE, BIRDIE, PAR, BOGEY, etc.)       
#> 11 year            Tournament year                                              
#> 12 field_avg       Field scoring average on the hole in that round (hosted data…
#> 13 to_par          Score relative to par on the hole (hosted data only)         
#> 14 vs_field        Strokes vs the field average on the hole (hosted data only)  
#> 15 cume_to_par     Running tournament score to par through the hole, playoff ho…