Skip to contents

add_loop_edu_disrupted_d() adds the education disruption and binaries and add_loop_edu_disrupted_d_to_main() adds the education disruption summarised binaries and the category to the main dataset.

Usage

add_loop_edu_disrupted_d(
  df,
  occupation = "edu_disrupted_occupation",
  hazards = "edu_disrupted_hazards",
  displaced = "edu_disrupted_displaced",
  teacher = "edu_disrupted_teacher",
  levels = c("yes", "no", "dnk", "pnta"),
  ind_schooling_age_d = "edu_ind_schooling_age_d"
)

add_loop_edu_disrupted_d_to_main(
  main,
  loop,
  occupation_d = "edu_disrupted_occupation_d",
  hazards_d = "edu_disrupted_hazards_d",
  displaced_d = "edu_disrupted_displaced_d",
  teacher_d = "edu_disrupted_teacher_d",
  id_col_main = "uuid",
  id_col_loop = "uuid"
)

Arguments

df

A data frame.

occupation

Column name for occupation disruption. NULL if dimension is not present in the data frame.

hazards

Column name for hazards disruption.

displaced

Column name for displaced disruption.

teacher

Column name for teacher disruption.

levels

Vector of levels for the disruption variables.

ind_schooling_age_d

Column name for the dummy variable of the schooling age class.

main

A data frame of household-level data.

loop

A data frame of individual-level data.

occupation_d

Column name for the dummy variable of the occupation dimension. NULL if dimension is not present in the data frame.

hazards_d

Column name for the dummy variable of the hazards dimension.

displaced_d

Column name for the dummy variable of the displaced dimension.

teacher_d

Column name for the dummy variable of the teacher dimension.

id_col_main

Column name for the unique identifier in the main dataset.

id_col_loop

Column name for the unique identifier in the loop dataset.