Results Stratifier
This module contains tools for stratifying observed quantities by specified characteristics through the vivarium results interface.
- class vivarium_public_health.results.stratification.ResultsStratifier[source]
A component for registering common public health stratifications.
The purpose of this component is to encapsulate all common public health stratification registrations in one place. This is not enforced, however, and stratification registrations can be done in any component.
- age_bins
The age bins for stratifying by age.
- start_year
The start year of the simulation.
- end_year
The end year of the simulation.
- setup(builder)[source]
Set up the stratifier.
Define age bins and simulation years and register default stratifications.
- map_age_groups(pop)[source]
Map age with age group name strings.
- Parameters:
pop (
DataFrame) – A table with one column, an age to be mapped to an age group name string.- Return type:
Series- Returns:
The age group name strings corresponding to the pop passed into the function.