generate_household_head_ages#

generate_household_head_ages(household_sizes, hha_by_size, hha_brackets, ages_left_to_assign)[source]#

Generate the head of household ages conditional on household size and the expected ages of people in the population.

Parameters:
  • household_sizes (np.array) – Array of household sizes to be generated

  • hha_by_size (matrix) – A matrix in which each row contains the age distribution of the reference person for household size s at index s-1.

  • hha_brackets (dict) – The age brackets for the heads of household.

  • ages_left_to_assign (dic) – The counter of ages for the generated population left to place in a residence

Returns:

An array of head of household ages, updated counter of the ages in the population left to place in a residence.