The ipums_extract class provides a data structure for storing the
definition and status of a submitted or unsubmitted IPUMS data extract,
for the purpose of interacting with the IPUMS extract API.
It is a superclass encompassing all of the collection-specific extract classes.
All objects with class ipums_extract will also have a collection-specific
subclass (e.g. usa_extract, cps_extract) to accommodate
collection-specific differences in extract options and contents, but all
these subclasses share similarities as described below.
For an overview of ipumsr microdata API functionality, see
vignette("ipums-api", package = "ipumsr").
ipums_extractObjects of class ipums_extract have:
A class attribute of the form c("<collection>_extract", "ipums_extract")
(e.g. c("cps_extract", "ipums_extract")).
A base type of "list".
A names attribute that is a character vector the same length as the
underlying list.
ipums_extractObjects of class ipums_extract:
Can be created from scratch with a function that has a name of the form
define_extract_<collection>() (e.g. define_extract_usa()).
Can be created from existing extract definitions with functions
define_extract_from_json() and get_extract_info().
Can be submitted for processing with submit_extract(). After submission,
you can have your R session periodically check the status of the submitted
extract, and wait until it is ready to download, with wait_for_extract().
You can also check whether it is ready to download directly with
is_extract_ready().
Can be revised with add_to_extract() and remove_from_extract().
Can be saved to a JSON-formatted file with save_extract_as_json().