get_bulk_patent_data: Get Bulk Patent Data from USPTO

Description Usage Arguments Value Examples

View source: R/acquire.R

Description

Download and convert bulk patent data to tidy format from the USPTO website <https://bulkdata.uspto.gov>. Data can be returned as a data frame or written to a file (see 'output_file' parameter). Since USPTO issues patents weekly, at minimum, all patents from a given week must be acquired at once.

Usage

1
get_bulk_patent_data(year, week, output_file)

Arguments

year

integer vector containing years from which patents should be collected

week

integer vector of weeks within the corresponding 'year' element from which patents should be collected

output_file

variable of class 'character'; will output to that file in CSV format

Value

either 'TRUE' (placeholder) or object of class 'data.frame' (see param 'output_file' for details)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## NOTE: none of the examples are run due to the download requirement
## Not run: 
# download patents from the first week of 1976 and get data frame
patent_data <- get_bulk_patent_data(year = 1976, week = 1)

# download patents from the last 5 weeks of 1980 (and write to a file)
get_bulk_patent_data(year = rep(1980, 5), week = 48:52,
                     output_file = "patent-data.csv")

## End(Not run)

patentr documentation built on Sept. 12, 2021, 5:07 p.m.