Score Simulation Model

Submodules

models.score.score module

Predicts the absolute risk of cardiovascular disease based on the input parameters.

Args:

age (int): Age of the individual (between 20 and 100). sex (int): Gender of the individual (1 for Men, 0 for Women). cholesterol (float): Cholesterol level in mmol/L (between 2 and 10). sbp (float): Systolic blood pressure in mmHg (between 80 and 250). smoker_status (int): Smoker status score. country (str): Country of the individual.

Returns:

float: Absolute risk of cardiovascular disease.

class biomodel.models.score.score.ScoreModel

Bases: CustomModel

Predicts the absolute risk of cardiovascular disease based on the input parameters.

Args:

age (int): Age of the individual (between 20 and 100). sex (int): Gender of the individual (1 for Men, 0 for Women). cholesterol (float): Cholesterol level in mmol/L (between 2 and 10). sbp (float): Systolic blood pressure in mmHg (between 80 and 250). smoker_status (int): Smoker status score. country (str): Country of the individual.

Returns:

float: Absolute risk of cardiovascular disease.

interpretation = 'probability'
intervals = [RiskInterval(value=0.01, name='Very Low risk'), RiskInterval(value=0.02, name='Low risk'), RiskInterval(value=0.035, name='Medium risk'), RiskInterval(value=0.05, name='High risk'), RiskInterval(value=0.1, name='Very High risk')]
name = 'SCORE'
predict(age: AgeInt(id='age', minimum=20, maximum=100, name='Age'), sex: Enum(id='sex', values={1: 'Male', 2: 'Female'}, name='Sex'), cholesterol: Float(id=4224820, minimum=2, maximum=10, name='Cholesterol (mmol/L)'), sbp: Float(id=4152194, minimum=80, maximum=250, name='Systolic blood pressure (mmHg)'), smoker_status: Enum(id=1585856, values={0: 'non-smoker', 1: 'smoker'}, name='Smoker Status'), country: Enum(id=4329169, values=['Albania', 'Algeria', 'Andorra', 'Armenia', 'Austria', 'Azerbaijan', 'Belarus', 'Belgium', 'Bulgaria', 'Cyprus', 'Denmark', 'Egypt', 'FYR Macedonia', 'Finland', 'France', 'Georgia', 'Germany', 'Greece', 'Iceland', 'Ireland', 'Israel', 'Italy', 'Kazakhstan', 'Kyrgyzstan', 'Latvia', 'Luxembourg', 'Malta', 'Moldova', 'Monaco', 'Norway', 'Portugal', 'Russian Federation', 'San Marino', 'Slovenia', 'Spain', 'Sweden', 'Switzerland', 'Syrian Arab Republic', 'Tajikistan', 'The Netherlands', 'Turkmenistan', 'Ukraine', 'United Kingdom', 'Uzbekistan'], name='Country')) float

Predicts the absolute risk of cardiovascular disease based on the input parameters.

Args:

age (int): Age of the individual (between 20 and 100). sex (int): Gender of the individual (1 for Men, 0 for Women). cholesterol (float): Cholesterol level in mmol/L (between 2 and 10). sbp (float): Systolic blood pressure in mmHg (between 80 and 250). smoker_status (int): Smoker status score. country (str): Country of the individual.

Returns:

float: Absolute risk of cardiovascular disease.

title = 'Probability of fatal cardiovascular disease in the next 10 years'

models.score.score_model module

Calculate survival probabilities, 10-year survival probability, 10-year risk, combined CVD risk, underlying survival probability, coefficients, and weighted sum based on risk factors and disease type.

biomodel.models.score.score_model.calculate_survival_probabilities(sy_age, sy_age_10, w)

Calculate the survival probabilities S(age) and S(age + 10).

biomodel.models.score.score_model.calculate_sy(age, a, p)

Calculate the underlying survival probability.

biomodel.models.score.score_model.calculate_weighted_sum(cholesterol, sbp, current_smoker, disease_type)

Calculate the weighted sum based on risk factors and disease type.

biomodel.models.score.score_model.combined_cvd_risk(chd_risk, non_chd_risk)

Combine risks for CHD and non-CHD CVD.

biomodel.models.score.score_model.get_coefficients(risk, gender, disease)

Get the coefficients a and p for given risk level, gender, and disease type.

biomodel.models.score.score_model.main(age, cholesterol, sbp, smoker_status, risk, gender)
biomodel.models.score.score_model.ten_year_risk(s_10_years)

Calculate the 10-year risk.

biomodel.models.score.score_model.ten_year_survival_probability(s_age, s_age_10)

Calculate the 10-year survival probability.

Module contents