I am trying to scrape a table of legislators from the following website: https://www.legis.ga.gov/members/house
First I tried Rvest, but that did not work because the page is dynamically generated.
library(rvest)
url <- 'https://www.legis.ga.gov/members/house'
page = read_html(url)
page %>%
html_element("table") %>%
html_table()
#Error in View : no applicable method for 'html_table' applied to an object of class "xml_missing"
Then I tried RSelenium. That did not work because it could not determine server status.
library(RSelenium)
rD = rsDriver(browser="chrome", port=4234L, chromever="109.0.5414.74")
#Warning message:
#In rsDriver(browser = "chrome", port = 4234L, chromever = "109.0.5414.74") :
# Could not determine server status.
library(wdman)
selServ <- wdman::selenium(verbose = FALSE)
selServ$log()
#$stderr
#[1] ""
#
#$stdout
#[1] ""
Then I tried to install the Splash package. I got this warning:
"Warning in install.packages : package ‘splashr’ is not available for this version of R"
Looking at other Stackoverload questions, several suggest downloading something called Docker (e.g., How to set up rselenium for R?). But it looks like this will then involve launching Docker and doing several complicated steps each time I need to scrape something. It doesn't make sense to go through all those steps to scrape a single table. I'm also leery of downloading software if it's not necessary. What is the simplest way to scrape this table? Am I missing something obvious that I was supposed to do?
For reference: I am using Chrome version 109.0.5414.119 on macOS Ventura, R Version 4.2.0.