I'm new to rvest and I'm trying to determine if its possible to use rvest to click a tab that activates a div so that data can be scraped. I've been reading the rvest documentation on cran and have not read anything that talks about clicking links, buttons or tabs.
The site that I'm interested in scraping is: touch.tvg.com
From the home page I'd like to click the race button (Again, how do you clik buttons in rvest)
Next, I'd like to select an upcoming race. This should redirect me to the selected race's url. For example: The 10th race at Hoosier
Once one the race page, I'd like to click the Pool tab and scrape the pool information.
I've attached some screen shots below. Any suggestion, guidance is appreciated.
From Home Page - Click Races Button
From Races Page - Click an upcoming Race
From The Particular Race Page - Click The Pool Tab
With the Pool data (Div) visible - Scrape the Pool Data.
In general, web scraping in R (or in any other language) boils down to the following three steps: Get the HTML for the web page that you want to scrape. Decide what part of the page you want to read and find out what HTML/CSS you need to select it. Select the HTML and analyze it in the way you need.
Overview. rvest helps you scrape (or harvest) data from web pages. It is designed to work with magrittr to make it easy to express common web scraping tasks, inspired by libraries like beautiful soup and RoboBrowser.
rvest is new package that makes it easy to scrape (or harvest) data from html web pages, inspired by libraries like beautiful soup. It is designed to work with magrittr so that you can express complex operations as elegant pipelines composed of simple, easily understood pieces.
RSelenium seems to offer all the functionality needed to harvest the data of interest. The best results might be achieved by combining the strength of rselenium with those of rvest.
Thank to everyone for their comments.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With