Hello everyone,
I am webscrapping a site that contains data embedded in multiple table classes, up to 200 of those per html page. If I use:
*Data_Number <-Data_Content %>%*
*html_node(".TableDataArchive") %>%*
*html_table()*
**it will extract ony one set of values**
**To extract all of the data from each page I have to create 200 of these commands**
*Data_Number_6 <- Data_Content %>%*
*html_node(".TableDataArchive:nth-child(6)") %>%*
*html_table()*
*Data_Number_7 <- Data_Content %>%*
*html_node(".TableDataArchive:nth-child(7)") %>%*
*html_table()*
*Data_Number_n+1 <- Data_Content %>%*
*html_node(".TableDataArchive:nth-child(n+1)") %>%*
*html_table()*
Is there a smart way to use for () to parse the value into nth-child(n+1) ? I did try different approaches all did not work. Or maybe some one can point me to a documentation/examples I can use?
Errors were like
> Error in if (a == 1 && b_min_1 <= 0) { :
> missing value where TRUE/FALSE needed