Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

get_nfl_boxscore_players(game_id = "401220131") #10

Open
Grayhawk34 opened this issue Apr 6, 2021 · 4 comments
Open

get_nfl_boxscore_players(game_id = "401220131") #10

Grayhawk34 opened this issue Apr 6, 2021 · 4 comments

Comments

@Grayhawk34
Copy link

Grayhawk34 commented Apr 6, 2021

Hi,

I'm trying to use the function get_nfl_boxscore_players with game_id = "401220131" but it's not working. This is the 9/13/2020 MIA vs. NE game. Other functions recognize this game_id (e.g. get_nfl_pbp(game_id="401220131") works.

Here's the error that I am getting:
player_game = get_nfl_boxscore_players(game_id = "401220131");
Error: Problem with mutate() input ..1.
x 'list' object cannot be coerced to type 'double'
i Input ..1 is across(c(pass_yds:punt_long), ~suppressWarnings(as.double(.x))).
Run rlang::last_error() to see where the error occurred.

@jthomasmock
Copy link
Owner

jthomasmock commented Jul 15, 2021

Hi @Grayhawk34 I believe this is working in latest release (0.5) as I've redone the function. Can you please confirm?

remotes::install_github("jthomasmock/espnscrapeR")
get_nfl_boxscore_players(game_id = "401220131")
# A tibble: 79 x 84
   game_id  game_uid season season_type date   week home_away winner team_id team_uid
   <chr>    <chr>     <int>       <int> <chr> <int> <chr>      <int> <chr>   <chr>   
 1 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 2 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 3 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 4 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 5 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 6 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 7 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 8 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
 9 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
10 4012201… s:20~l:…   2020           2 2020…     1 away           0 15      s:20~l:…
# … with 69 more rows, and 74 more variables: team_city <chr>, team_name <chr>,
#   team_abb <chr>, team_full <chr>, team_color <chr>, team_color_alt <chr>,
#   team_logo <chr>, team_order <int>, team_score <int>, team_record <chr>,
#   text <chr>, player_id <chr>, player_uid <chr>, player_guid <chr>,
#   first_name <chr>, last_name <chr>, full_name <chr>, pass_att <int>,
#   pass_cmp <int>, pass_yds <dbl>, pass_avg <dbl>, pass_td <dbl>, pass_int <dbl>,
#   pass_sacks <dbl>, pass_sack_yds <dbl>, pass_qbr <dbl>, pass_rtg <dbl>,
#   rush_att <dbl>, rush_yds <dbl>, rush_avg <dbl>, rush_td <dbl>, rush_long <dbl>,
#   rec_total <dbl>, rec_yds <dbl>, rec_avg <dbl>, rec_td <dbl>, rec_long <dbl>,
#   rec_tgts <dbl>, fum_total <dbl>, fum_lost <dbl>, fum_rec <dbl>, def_tkl <dbl>,
#   def_solo_tkl <dbl>, def_sacks <dbl>, def_tfl <dbl>, def_pd <dbl>,
#   def_qb_hts <dbl>, def_td <dbl>, int_total <dbl>, int_yds <dbl>, int_td <dbl>,
#   kick_ret_no <dbl>, kick_ret_yds <dbl>, kick_ret_avg <dbl>, kick_ret_long <dbl>,
#   kick_ret_td <dbl>, punt_ret_no <dbl>, punt_ret_yds <dbl>, punt_ret_avg <dbl>,
#   punt_ret_long <dbl>, punt_ret_td <dbl>, kick_fg_att <dbl>, kick_fg_made <dbl>,
#   kick_pct <dbl>, kick_long <dbl>, kick_xp_att <dbl>, kick_xp_made <dbl>,
#   kick_pts <dbl>, punt_no <dbl>, punt_yds <dbl>, punt_avg <dbl>, punt_tb <dbl>,
#   punt_in_20 <dbl>, punt_long <dbl>

@Grayhawk34
Copy link
Author

I'm getting the following error:

Error in open.connection(con, "rb") : HTTP error 403.

Never had this before.

@jthomasmock
Copy link
Owner

Hi @Grayhawk34 - that means a forbidden pathway.

Can you confirm that you have:

  • Installed the latest version of the espnscrapeR package w/ remotes::install_github("jthomasmock/espnscrapeR")
  • That you can navigate to the raw url here ?

@Grayhawk34
Copy link
Author

Grayhawk34 commented Jul 18, 2021 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants