Description Usage Arguments Value Examples
Returns information (e.g., product names, product ratings, number of ratings, detail page urls) listed in a geizhals page that is listing all products within a specific category (i.e., not the generic page-wide search from the search bar, but the page showing all items within a category. Filters might be applied, only results corresponding to that filter will be shown and scraped.) The order of items returned by the function might not correspond to the order listed on the webpage, but it is the same order in all related functions.
1 | parse_single_listpage(listpagehtml, domain = "https://geizhals.at")
|
listpagehtml |
html structure from a single geizhals page listing
items in a selected category, as gathered via |
domain |
Character vector of length one specifying the domain.
Defaults to |
A tibble (data.frame) containing all information scraped from the geizhals page.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | ## Not run:
## get html of a geizhals category listing page via read_html:
url_geizhals <- "https://geizhals.at/?cat=acam35"
listpagehtml <- xml2::read_html(url_geizhals)
parse_single_listpage(listpagehtml)
## get html of multiple geizhals category listing pages:
listpagehtml_list <- fetch_all_listpages(url_geizhals)
parse_single_listpage(listpagehtml_list[[1]])
## get html from a geizhals.eu page and parse:
url_geizhals <- "https://geizhals.eu/?cat=acam35"
listpagehtml <- xml2::read_html(url_geizhals)
parse_single_listpage(listpagehtml, domain = "https://geizhals.eu")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.