Construct a Socrata open data API (SODA) query for the NHSN Hospital Respiratory Data set.
Source:R/pull_nhsn.R
nhsn_soda_query.RdThis function has been replaced the more general
data_cdc_gov_soda_query(), which it now uses
internally. Use that function instead.
Usage
nhsn_soda_query(
api_endpoint,
start_date = NULL,
end_date = NULL,
columns = NULL,
jurisdictions = NULL,
limit = 1e+05,
order_by = c("jurisdiction", "weekendingdate"),
desc = FALSE,
...
)Arguments
- api_endpoint
Base API endpoint URL to use when constructing the query.
- start_date
Pull only rows with dates greater than or equal to this date. If
NULL, no minimum date. DefaultNULL.- end_date
Pull only rows with dates less than or equal to this date. If
NULL, no maximum date. DefaultNULL.- columns
Vector of columns to retrieve, in addition to
weekendingdateandjurisdiction, which are always retrieved. IfNULL, retrieve all columns. DefaultNULL.- jurisdictions
Vector of jurisdictions to retrieve, by two letter US postal service code. If
NULL, retrieve all. DefaultNULL.- limit
limit to the number of rows to retrieve. Default 1e5.
- order_by
Vector of columns by which to order the results. Default
c("jurisdiction", "weekendingdate")- desc
whether to order descending instead of ascending. Default
FALSE(order ascending).- ...
additional arguments passed to
data_cdc_gov_soda_query().
Value
the query as soql::soql() output