Scraping .aspx webpage

I'm trying to scrape the main data table from this page using rvest. Using the selectorgadget the html node for the table header is th however when I run the code I get {xml_nodeset (0)}. What am I missing here?

peelDSB <- ""

peelDSB %>% 
  read_html() %>% 
  html_nodes("th") %>%


If you right-click the webpage and view source, you will see that this table in fact is not embedded in the HTML but dynamically loaded in (likely because of aspx). This mean that conventional scraping with just getting the HTML will not work.

You might want to look into RSelenium, where you can scrape more complex webpages by automating a webbrowser. I don't know the exact implementation for your question here, but I'm sure Google (or someone here) can be helpful.


This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.