understatr
understatr copied to clipboard
Error in get_league_team_stats
get_league_team_stats(league_name = 'Ligue 1', year = 2020) throws this error:
Error in rbind(deparse, level, ...) : numbers of columns of arguments do not match.
same issue for teams and for players, get_team_players_stats(team_name = "Atletico Madrid", year = 2020) Error: lexical error: invalid char in json text. NA (right here) ------^
also with 2020/21 EPL get_league_teams_stats(league_name = "EPL", year = 2020) Error in rbind(deparse.level, ...) : numbers of columns of arguments do not match
any update? thanks
I cant recreate your error @vibhormbic91. Please include a minimal reproducible example (AKA a reprex). If you've never heard of a reprex before, start by reading https://www.tidyverse.org/help/#reprex.
@davidfombella file a new issue and do the same.
This error was showing up early in the season because not all teams had played a game till then. For the teams that hadn't played a game, their row in teams data was empty. So, the rbind (github.com/ewenme/understatr/master/R/leagues.R#L119) was throwing up an error.
Gotcha. I'll try and catch this for future seasons when I get a chance.