I am new to Rvest and am trying to get the Match IDs for each game played on a specific date in a specific league. I know to use html_nodes to look up classes or IDs, but I cannot access what I need here. Each match url looks like this http://www.espn.com/soccer/match?gameId=XXXXXX where XXXXXX is the match ID. This is what I am looking to get for all matches.
The match IDs I need to get are the IDs of the articles below what is written in the code below, but I cannot seem to get any lower in the HTML structure than this.
Can anyone suggest a fix for me? This might be generated on the server side?
library(rvest) url <- "http://www.espn.com/soccer/scoreboard/_/league/esp.1/date/20190106" scoreboard <- url %>% read_html() GameID <- scoreboard %>% html_nodes(xpath = '//*[@id="events"]')