save_code: Download one results page as html file

Description Usage Arguments Value Examples

View source: R/save_codes.R

Description

Downloads one page of CDC results from a URLs as html files with a specific wait-time to avoid IP address blocking.

Usage

1
save_code(url, browser = "firefox")

Arguments

url

One URLs corresponding to a page of CDC search results.

browser

The name of the browser used for scraping. Default is 'firefox'.

Value

An object containing the HTML code. A text file containing the html code is saved to the working directory.

Examples

1
2
url <- 'https://search.cdc.gov/search/index.html?all=disease%20spread&none=animal%20fish&exact=corona%20virus&any=pandemic%20global&date1=01%2F01%2F1980&date2=10%2F11%2F2020&dpage=1'
code <- save_code(url);

nealhaddaway/CDCscraper documentation built on Oct. 21, 2020, 5:20 a.m.