Defines the population life table data type.
More...
#include <life_table.h>
Defines the population life table data type.
◆ LifeTable() [1/2]
| hgps::LifeTable::LifeTable |
( |
| ) |
|
|
delete |
◆ LifeTable() [2/2]
| hgps::LifeTable::LifeTable |
( |
std::map< int, Birth > && | births, |
|
|
std::map< int, std::map< int, Mortality > > && | deaths ) |
Initialises a new instance of the LifeTable structure.
- Parameters
-
| births | Number of births per year |
| deaths | Number of deaths per year and age |
◆ age_limits()
Gets the LifeTable data age limits.
- Returns
- Data age limits
◆ contains_age()
| bool hgps::LifeTable::contains_age |
( |
int | age | ) |
const |
|
noexcept |
Determine whether the LifeTable data contains a given age.
- Parameters
-
- Returns
- true, if the LifeTable data contains the age; otherwise, false.
◆ contains_time()
| bool hgps::LifeTable::contains_time |
( |
int | time_year | ) |
const |
|
noexcept |
Determine whether the LifeTable data contains a given time.
- Parameters
-
| time_year | The time to check |
- Returns
- true, if the LifeTable data contains the time; otherwise, false.
◆ empty()
| bool hgps::LifeTable::empty |
( |
| ) |
const |
|
noexcept |
Determine whether the LifeTable data is empty.
- Returns
- true, if the LifeTable data is empty; otherwise, false.
◆ get_births_at()
| const Birth & hgps::LifeTable::get_births_at |
( |
int | time_year | ) |
const |
Gets the Birth indicators at a given time.
- Parameters
-
- Returns
- The Birth indicator
◆ get_mortalities_at()
| const std::map< int, Mortality > & hgps::LifeTable::get_mortalities_at |
( |
int | time_year | ) |
const |
Gets the Mortality indicators at a given time.
- Parameters
-
| time_year | Time of mortality |
- Returns
- The age associate Mortality indicators
◆ get_total_deaths_at()
| double hgps::LifeTable::get_total_deaths_at |
( |
int | time_year | ) |
const |
Gets the total number of deaths at a given time.
- Parameters
-
- Returns
- Total number of deaths
◆ time_limits()
Gets the LifeTable data time limits.
- Returns
- Data time limits
The documentation for this class was generated from the following files: