internal function to calculate ratios estimations
create_ratio_internal.Rd
internal function to calculate ratios estimations
Usage
create_ratio_internal(
var,
denominator,
domains = NULL,
subpop = NULL,
disenio,
ci = FALSE,
deff = FALSE,
ess = FALSE,
ajuste_ene = FALSE,
unweighted = FALSE,
rel_error = FALSE,
log_cv = FALSE,
rm.na = FALSE
)
Arguments
- var
numeric variable within the
dataframe
, is the numerator of the ratio to be calculated.- denominator
numeric variable within the
dataframe
, is the denominator of the ratio to be calculated.- domains
domains to be estimated separated by the + character.
- subpop
integer dummy variable to filter the dataframe
- disenio
complex design created by
survey
package- ci
boolean
indicating if the confidence intervals must be calculated- deff
boolean
Design effect- ess
boolean
Effective sample size- ajuste_ene
boolean
indicating if an adjustment for the sampling-frame transition period must be used- unweighted
boolean
Add non weighted count if it is required- rel_error
boolean
Relative error- log_cv
boolean
indicating if the log cv must be returned. Used for ratios between 0 and 1.- rm.na
boolean
indicating if NA values must be removed