View source: R/define-deprivation.R
| deprived | R Documentation |
compute_mpiA helper that captures a bare deprivation cutoff expression and
optional per-indicator settings for use inside the deprivations
argument of compute_mpi.
deprived(.cutoff, .data = NULL, collapse_fn = NULL, set_na_equal_to = 0, ...)
.cutoff |
A bare logical expression evaluated against the indicator's
data frame. Rows where this evaluates to |
.data |
An optional data frame to use for this indicator instead of the
primary |
collapse_fn |
An optional function applied to collapse roster-level
data to the unit-of-analysis level (e.g. |
set_na_equal_to |
Coerce |
... |
Reserved; passing old dotted names (e.g. |
An object of class mpi_d.
compute_mpi
deprived(drinking_water == 2)
deprived(undernourished == 1 & age < 70, .data = df_household_roster, collapse_fn = max)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.