I have been trying to scrape live quotes form this website but am running into an error. The code I used is given below
library(XML)
webpage='http://quotes.freerealtime.com/dl/frt/M?SA=Percent+Gainers&IM=stats&stat=3'
# parse url
url_parsed <- htmlParse(getURL(webpage), asText = TRUE)
# select table nodes of interest
tableNodes <- getNodeSet(url_parsed, '/html/body/table[2]/tbody/tr/td[4]/table[2]/tbody/tr[2]/td/table')
But the tableNodes
turns out to be NULL
. Can anyone help me figure this out?