Add healthcare needed category to loop data (incl. WGQ-SS if provided)
Source:R/add_loop_healthcare_needed_cat.R
add_loop_healthcare_needed_cat.Rd
Add healthcare needed category to loop data (incl. WGQ-SS if provided)
Usage
add_loop_healthcare_needed_cat(
loop,
ind_healthcare_needed = "health_ind_healthcare_needed",
ind_healthcare_needed_levels = c("no", "yes", "dnk", "pnta"),
ind_healthcare_received = "health_ind_healthcare_received",
ind_healthcare_received_levels = c("no", "yes", "dnk", "pnta"),
wgq_dis = NULL,
ind_age = "ind_age"
)
add_loop_healthcare_needed_cat_to_main(
main,
loop,
ind_healthcare_needed_no = "health_ind_healthcare_needed_no",
ind_healthcare_needed_yes_unmet = "health_ind_healthcare_needed_yes_unmet",
ind_healthcare_needed_yes_met = "health_ind_healthcare_needed_yes_met",
ind_healthcare_needed_no_wgq_dis = NULL,
ind_healthcare_needed_yes_unmet_wgq_dis = NULL,
ind_healthcare_needed_yes_met_wgq_dis = NULL,
id_col_main = "uuid",
id_col_loop = "uuid"
)
Arguments
- loop
A data frame of individual-level data.
- ind_healthcare_needed
The name of the variable that indicates if healthcare is needed.
- ind_healthcare_needed_levels
A character vector of levels for ind_healthcare_needed.
- ind_healthcare_received
The name of the variable that indicates if healthcare is received.
- ind_healthcare_received_levels
A character vector of levels for ind_healthcare_received.
- wgq_dis
The name of the variable that indicates if the individual has a disability (usual cut-offs are 3).
- ind_age
The name of the variable that indicates the age of the individual.
- main
A data frame of household-level data.
- ind_healthcare_needed_no
The binary variable that indicates if healthcare is not needed.
- ind_healthcare_needed_yes_unmet
The binary variable that indicates if healthcare is needed but unmet.
- ind_healthcare_needed_yes_met
The binary variable that indicates if healthcare is needed and met.
- ind_healthcare_needed_no_wgq_dis
The binary variable that indicates if healthcare is not needed and the individual has a disability.
- ind_healthcare_needed_yes_unmet_wgq_dis
The binary variable that indicates if healthcare is needed but unmet and the individual has a disability.
- ind_healthcare_needed_yes_met_wgq_dis
The binary variable that indicates if healthcare is needed and met and the individual has a disability.
- id_col_main
The column name for the unique identifier in the main data frame.
- id_col_loop
The column name for the unique identifier in the loop data frame.