View source: R/derive_var_dthcaus.R
dthcaus_source | R Documentation |
dthcaus_source
Object The derive_var_dthcaus()
function and dthcaus_source()
have been superseded in favor of
derive_vars_extreme_event()
.
dthcaus_source(
dataset_name,
filter,
date,
order = NULL,
mode = "first",
dthcaus,
set_values_to = NULL
)
dataset_name |
The name of the dataset, i.e. a string, used to search for the death cause. |
filter |
An expression used for filtering |
date |
A date or datetime variable or an expression to be used for
sorting |
order |
Sort order Additional variables/expressions to be used for sorting the Permitted Values: list of expressions created by |
mode |
One of |
dthcaus |
A variable name, an expression, or a string literal If a variable name is specified, e.g., |
set_values_to |
Variables to be set to trace the source dataset |
An object of class "dthcaus_source".
derive_var_dthcaus()
Other superseded:
date_source()
,
derive_param_extreme_record()
,
derive_var_dthcaus()
,
derive_var_extreme_dt()
,
derive_var_extreme_dtm()
,
get_summary_records()
# Deaths sourced from AE
src_ae <- dthcaus_source(
dataset_name = "ae",
filter = AEOUT == "FATAL",
date = AEDTHDT,
mode = "first",
dthcaus = AEDECOD
)
# Deaths sourced from DS
src_ds <- dthcaus_source(
dataset_name = "ds",
filter = DSDECOD == "DEATH",
date = convert_dtc_to_dt(DSSTDTC),
mode = "first",
dthcaus = DSTERM
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.