I have a simple piece of R code which reads html data from a website then I am trying to loop through the pages and get data from each page. I have used this piece of code numerous times and it works. It adds to a R variable the results from each page but for some reason on this site it wont work. Any ideas?
library(XML)
library(RCurl)
data <- NULL
getData <- function(url) {
#For some reason cant read directly from site, need to use RCurl to get the data first
xData <- getURL(url)
table <- data.frame(readHTMLTable(xData)$'NULL')
data <- table
}
getData(url="https://steemdb.com/accounts/reputation?page=1")