title: Web scraping a table: Error using rvest and splash
body: <p>I am trying to scrape a table from this link (<a href="https://www.sac-isc.gc.ca/eng/1620925418298/1620925434679" rel="nofollow noreferrer">https://www.sac-isc.gc.ca/eng/1620925418298/1620925434679</a>). I have tried two approaches so far:</p>
  <ol>
  <li>Using rvest though I couldn't find HTML nodes on the page for the table</li>
  <li>Using splash, assuming the page is being loaded dynamically</li>
  </ol>
  <p>Neither of the approaches seem to be working for me. After hours of trying and reading posts/blogs, etc, I can't seem to figure out what I'm missing. Can someone please point me to the right direction or atleast tell me what I'm doing wrong? Thanks!</p>
  <p>Scraping using rvest:</p>
  <pre><code>library(rvest)
  
  loadedTable &lt;- read_html(&quot;https://www.sac-isc.gc.ca/eng/1620925418298/1620925434679&quot;) %&gt;%
  
  html_nodes(&quot;table&quot;) %&gt;%
  
  html_table() %&gt;%
  
  as.tbl()
  </code></pre>
  <p>Error:</p>
  <pre><code>Error in matrix(unlist(values), ncol = width, byrow = TRUE) :
  
  'data' must be of a vector type, was 'NULL'
  </code></pre>
  <p>Scraping using splashr:</p>
  <pre><code>library(splashr)
  library(reticulate)
  
  install_splash()
  
  splash(&quot;localhost&quot;) %&gt;% splash_active()
  
  sp &lt;- start_splash()
  
  pg &lt;- render_html(url = 'https://www.sac-isc.gc.ca/eng/1620925418298/1620925434679')
  
  stop_splash(sp)
  
  loadedTable1 &lt;- pg %&gt;% 
    html_node('table') %&gt;% 
    html_table()
  
  loadedTable1
  </code></pre>
  <p>Error:</p>
  <pre><code>Did not find required python module 'docker'
  Error in curl::curl_fetch_memory(url, handle = handle) : 
    Failed to connect to localhost port 8050: Connection refused
  Error in stop_splash(sp) : object 'sp' not found
  Error in html_element(...) : object 'pg' not found
  Error: object 'loadedTable1' not found
  </code></pre>