jflancer / bigballR

Package for working with NCAA Basketball Data
Other
61 stars 19 forks source link

Subscript out of bounds on get_team_schedule #32

Closed gitmoneyMSBA closed 1 year ago

gitmoneyMSBA commented 1 year ago

Tried downloading the newest version of bigballR from the install_github on the home page and got the same issue.

Here is the code I ran and the error it produced:

schedule <- get_team_schedule(season = "2022-23", team.name = "Illinois")

Error in tables[[2]] : subscript out of bounds

If I try to pluck a specific game off of the stats.ncaa.org website, I get the following issue:

illinois_game <- get_play_by_play(c(2143269))

[1] "Error with game id: 2143269 // Error: XML content does not seem to be XML: ''\n"
2143269 removed
evanmiyakawa commented 1 year ago

It works fine for me with this script:

library(bigballR)

schedule <- get_team_schedule(season = "2022-23", team.name = "Illinois")

get_play_by_play(c(schedule$Game_ID[1]))
Screen Shot 2022-11-30 at 4 17 46 PM
mattrhein commented 1 year ago

On a similar note, getting a different error now with the same function.

get_team_schedule(season = "2022-23", team.name = "Dayton")

Error in readLines(con = file_url, warn = F) : cannot open the connection to 'http://stats.ncaa.org/teams/542056' In addition: Warning message: In readLines(con = file_url, warn = F) : URL 'http://stats.ncaa.org/teams/542056': status was 'Couldn't connect to server'

mattrhein commented 1 year ago

On a similar note, getting a different error now with the same function.

get_team_schedule(season = "2022-23", team.name = "Dayton")

Error in readLines(con = file_url, warn = F) : cannot open the connection to 'http://stats.ncaa.org/teams/542056' In addition: Warning message: In readLines(con = file_url, warn = F) : URL 'http://stats.ncaa.org/teams/542056': status was 'Couldn't connect to server'

Disregard, works fine now!