Health-GPS  1.2.2.0
Global Health Policy Simulation model (Health-GPS)
lms_model.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "lms_definition.h"
4 #include "person.h"
5 
7 #include <functional>
8 #include <string>
9 
10 namespace hgps {
11 
13 class LmsModel {
14  public:
15  LmsModel() = delete;
16 
20  LmsModel(LmsDefinition &definition);
21 
24  unsigned int child_cutoff_age() const noexcept;
25 
29  WeightCategory classify_weight(const Person &entity) const;
30 
37  double adjust_risk_factor_value(const Person &entity, const core::Identifier &factor_key,
38  double value) const;
39 
40  private:
41  std::reference_wrapper<LmsDefinition> definition_;
42  unsigned int child_cutoff_age_{18};
43  core::Identifier bmi_key_{"bmi"};
44 
45  WeightCategory classify_weight_bmi(const Person &entity, double bmi) const;
46 };
47 } // namespace hgps
LMS (lambda-mu-sigma) model definition data type.
Definition: lms_definition.h:26
Implements the LMS (lambda-mu-sigma) model for children growth.
Definition: lms_model.h:13
double adjust_risk_factor_value(const Person &entity, const core::Identifier &factor_key, double value) const
Adjust a Person risk factor value.
Definition: lms_model.cpp:23
WeightCategory classify_weight(const Person &entity) const
Classify a person weight according with the predefined categories.
Definition: lms_model.cpp:18
LmsModel()=delete
unsigned int child_cutoff_age() const noexcept
Gets the children cut-off age (before adult)
Definition: lms_model.cpp:16
Top-level namespace for Health-GPS C++ API.
Definition: analysis_definition.h:8
WeightCategory
Enumerates the Person weight categories.
Definition: weight_category.h:7
Global namespace.
Definition: jsonparser.h:88
Defines a virtual population person data type.
Definition: person.h:40
Entity unique identifier data type.
Definition: identifier.h:17