I'm having some problems scraping data from a website. I do have not a lot of experience with web-scraping. My intended plan is to scrape some data using R from the following website: https://www.myfxbook.com/forex-broker-swaps
More precisely, I want to extract the Forex Brokers Swap Comparison for all the available pairs.
My idea so far:
library(XML)
url <- paste0("https://www.myfxbook.com/forex-broker-swaps")
source <- readLines(url, encoding = "UTF-8")
parsed_doc <- htmlParse(source, encoding = "UTF-8")
test<-xpathSApply(parsed_doc, path = '/html/body/div[3]/div[6]/div/div/div/div/div/div/div/div/div[3]/div[4]/div/div[2]/div', xmlValue)
But this doesn't bring up the intended information. Some help would be really appreciated here! Thanks!