I am trying to webscrape the Defence Table from the following page: https://www.pro-football-reference.com/boxscores/202402110kan.htm
Note there are multiple tables on this page so you need to scroll down a bit to see the defence table
I have used the following code
url <- “https://www.pro-football-reference.com/boxscores/202402110kan.htm”
table_defence <- url %>% read_html %>% html_node(‘#div_all_player_defense’) %>% html_table()
However I get the following error
Error in UseMethod(“html_table”) :
no applicable method for ‘html_table’ applied to an object of class “xml_missing”
Based on the URL I am not sure if this issue is because the URL has HTM rather than HTML?
I have tried using rvest but open to use another solution if that works.