1(if (parseFloat([med_oac])==0), performActions: [tx_asa]->enable)
2If all outcomes selected, enable all(if [important_outcome]==6
, performActions: [tx_acei]->enable, [tx_asa]->enable, [tx_dpp4i]->enable, [tx_ezetimibe]->enable, [tx_glp1ra]->enable, [insulin]->enable, [sulfonylurea]->enable, [tx_metformin]->enable, [tx_sglt2i]->enable, [bp_target_on]->enable, [tx_statin]->enable, [finerenone]->enable)
3Albuminuria, change SGLT2i & ACEI renal benefit(if (parseFloat([acr])>=23), setBenefit: rr_esrd -> 0.65, rr_esrd -> 0.60)
4If outcome ESRD, disable interventions with RR=1(if [important_outcome]==3, performActions: [tx_dpp4i]->disable, [tx_glp1ra]->enable, [tx_metformin]->disable, [tx_sglt2i]->enable, [tx_acei]->enable, [tx_asa]->disable, [tx_ezetimibe]->disable, [tx_statin]->disable, [bp_target_on]->disable, [sulfonylurea]->disable, [insulin]->disable, [finerenone]->enable)
5If outcome neuropathy, disable interventions with RR=1(if [important_outcome]==5, performActions: [tx_dpp4i]->disable, [tx_glp1ra]->disable, [tx_metformin]->disable, [tx_sglt2i]->disable, [tx_acei]->disable, [tx_asa]->disable, [tx_ezetimibe]->disable, [tx_statin]->disable, [bp_target_on]->disable, [sulfonylurea]->disable, [insulin]->disable, [finerenone]->disable)
6If outcome HF, disable interventions with RR=1(if [important_outcome]==2, performActions: [tx_dpp4i]->disable, [tx_glp1ra]->disable, [tx_metformin]->disable, [tx_sglt2i]->enable, [tx_acei]->enable, [tx_asa]->disable, [tx_ezetimibe]->disable, [tx_statin]->disable, [bp_target_on]->enable, [sulfonylurea]->disable, [insulin]->disable, [finerenone]->enable)
7If outcome death, disable interventions with RR=1(if [important_outcome]==0, performActions: [tx_dpp4i]->disable, [tx_glp1ra]->enable, [tx_metformin]->disable, [tx_sglt2i]->enable, [tx_acei]->enable, [tx_asa]->disable, [tx_ezetimibe]->disable, [tx_statin]->enable, [bp_target_on]->enable, [sulfonylurea]->disable, [insulin]->disable, [finerenone]->enable)
8If outcome ASCVD, disable interventions with RR=1(if [important_outcome]==1, performActions: [tx_dpp4i]->disable, [tx_glp1ra]->enable, [tx_metformin]->enable, [tx_sglt2i]->enable, [tx_acei]->enable, [tx_asa]->enable, [tx_ezetimibe]->enable, [tx_statin]->enable, [insulin]->disable, [sulfonylurea]->disable, [finerenone]->disable, [bp_target_on]->enable)
9A1C - as percent(if ([a1c_unit_selection]=="pct"), showHideTags: show tags: (a1c_pct) hide tags: (a1c_mmol))
10Already taking OAC, disable ASA in step 2 (not turning off after deselecting OAC)(if (parseFloat([med_oac])==1), performActions: [tx_asa]->disable)
11(if ([outcome]=="rr_death"), showHideTags: show tags: (death) hide tags: (ascvd, hf, esrd, retinopathy, neuropathy))
12(if ([outcome]=="rr_ascvd"), showHideTags: show tags: (ascvd) hide tags: (death, hf, esrd, retinopathy, neuropathy))
13(if ([outcome]=="rr_hf"), showHideTags: show tags: (hf) hide tags: (death, ascvd, esrd, retinopathy, neuropathy))
14(if ([outcome]=="rr_esrd"), showHideTags: show tags: (esrd) hide tags: (death, ascvd, hf, retinopathy, neuropathy))
15(if ([outcome]=="rr_retinopathy"), showHideTags: show tags: (retinopathy) hide tags: (death, ascvd, hf, esrd, neuropathy))
16(if ([outcome]=="rr_neuropathy"), showHideTags: show tags: (neuropathy) hide tags: (death, ascvd, hf, esrd, retinopathy))
17A1C - as mmol(if ([a1c_unit_selection]=="mmol"), showHideTags: show tags: (a1c_mmol) hide tags: (a1c_pct))
18Step 4 hide all options default (show instructions)(if 1==1, showHideTags: show tags: (instructions) hide tags: (flozin, glp1, metformin, ddp4, ezetimibe, asa, finerenone, statin_prior, bp, insulin, sulfonylurea, statin_new, acei_prior, acei_new))
19Show flozin options(if [tx_sglt2i]==1, showHideTags: show tags: (flozin) hide tags: (instructions))
20Show GLP1 options(if [tx_glp1ra]==1, showHideTags: show tags: (glp1) hide tags: (instructions))
21Show metformin options(if [tx_metformin]==1, showHideTags: show tags: (metformin) hide tags: (instructions))
22Show DDP4 options(if [tx_dpp4i]==1, showHideTags: show tags: (ddp4) hide tags: (instructions))
23Show ezetimibe options(if [tx_ezetimibe]==1, showHideTags: show tags: (ezetimibe) hide tags: (instructions))
24Show ACEI options(if [tx_acei]==1, showHideTags: show tags: (acei_new) hide tags: (instructions))
25Show ASA options(if [tx_asa]==1, showHideTags: show tags: (asa) hide tags: (instructions))
26Show finerenone options(if [finerenone]==1, showHideTags: show tags: (finerenone) hide tags: (instructions))
27If sbp toggled off then hide sbp range(if [bp_target_on]==0, showHideTags: hide tags: (sbp_target))
28If sbp toggled on then show sbp range and step 4(if [bp_target_on]==1, showHideTags: show tags: (sbp_target, bp) hide tags: (instructions))
29If "all outcomes", enable all(if [selected_or_all]==1, performActions: [tx_acei]->enable, [tx_asa]->enable, [tx_dpp4i]->enable, [tx_ezetimibe]->enable, [tx_glp1ra]->enable, [tx_metformin]->enable, [tx_sglt2i]->enable, [tx_statin]->enable, [finerenone]->enable, [bp_target_on]->enable, [sulfonylurea]->enable, [insulin]->enable)
30Show sulfonylurea options(if [sulfonylurea]==1, showHideTags: show tags: (sulfonylurea) hide tags: (insulin))
31Show insulin options(if [insulin]==1, showHideTags: show tags: (insulin) hide tags: (instructions))
32Disable treatments that have no effect on any outcome(if 1==1, performActions: [tx_dpp4i]->disable, [sulfonylurea]->disable, [insulin]->disable)
33Hide all monitoring by default(if 1==1, showHideTags: hide tags: (monitor_flozin, monitor_glp1, monitor_metformin, monitor_ddp4, monitor_statin, monitor_ezetimibe, monitor_acei, monitor_finerenone, monitor_bp, monitor_insulin, monitor_sulfonylurea, monitor_asa))
34disable finerenone if not CKD or UACR met(if (parseFloat([ckdepi])>=60) && (parseFloat([acr])<=30), performActions: [finerenone]->disable)
35If ddp4 selected and started then show monitoring(if ([tx_dpp4i]==1)&&([options_dpp]==0), showHideTags: )
36Hide all hide(if 1==1, showHideTags: hide tags: (hide))
37Flozin monitor(if [options_flozin]==0&&[tx_sglt2i]==1
, showHideTags: show tags: (monitor_flozin))
38GLP1 monitor(if [options_glp]==0&&[tx_glp1ra]==1, showHideTags: show tags: (monitor_glp1))
39DDP4 monitor(if [options_dpp]==0&&[tx_dpp4i]==1, showHideTags: show tags: (monitor_ddp4))
40Metformin(if [options_metformin]==0&&[tx_metformin]==1, showHideTags: show tags: (monitor_metformin))
41Statin monitor(if [options_statin]==0&&[tx_statin]==1, showHideTags: show tags: (monitor_statin))
42Ezetimibe monitor(if [options_ezetimibe]==0&&[tx_ezetimibe]==1, showHideTags: show tags: (monitor_ezetimibe))
43ACEI monitor(if [options_acei]==0&&[tx_acei]==1, showHideTags: show tags: (monitor_acei))
44ASA monitor(if [options_asa]==0&&[tx_asa]==1, showHideTags: show tags: (monitor_asa))
45Finerenone monitor(if [options_finerenone]==0&&[finerenone]==1, showHideTags: show tags: (monitor_finerenone))
46BP monitor(if [options_bp]==0&&[bp_target_on]==1, showHideTags: show tags: (monitor_bp))
47Insulin monitor(if [options_insulin]==0&&[insulin]==1, showHideTags: show tags: (monitor_insulin))
48Sulfonylurea monitor(if [options_sulfonylurea]==0&&[sulfonylurea]==1, showHideTags: show tags: (monitor_sulfonylurea))
49If not on OAC then hide ASA warning(if [med_oac]==0, showHideTags: hide tags: (asa_disable))
50Hide outcome definitions if toggle off(if [outcome_def_toggle]==0, showHideTags: hide tags: (definitions))
51Show outcome definitions if toggle on(if [outcome_def_toggle]==1, showHideTags: show tags: (definitions))
52If outcome retinopathy, disable interventions with RR=1(if [important_outcome]==4, performActions: [tx_dpp4i]->disable, [tx_glp1ra]->disable, [tx_metformin]->disable, [tx_sglt2i]->disable, [tx_acei]->disable, [tx_asa]->disable, [tx_ezetimibe]->disable, [tx_statin]->disable, [sulfonylurea]->disable, [insulin]->disable, [bp_target_on]->disable, [finerenone]->disable)
53hide warning(if 1==1, showHideTags: hide tags: (warning))
54show warning(if (parseFloat([ckdepi])>=60)
&&
(parseFloat([acr])<=30), showHideTags: show tags: (warning))
55Already taking statin, disable in step 2(if ([med_statin]=="1"), performActions: [tx_statin]->disableAlreadyTaking)
56Enable both antihypertensive options by default(if 1==1, performActions: [med_bp]->enable, [med_bp2]->enable)
57Only one antihypertensive option can be selected(if [med_bp2]==1, performActions: [med_bp]->disable)
58Show statin options(if ([tx_statin]==1), showHideTags: show tags: (statin_new) hide tags: (instructions))
59Show statin options (already taking)(if [med_statin]==1, showHideTags: show tags: (statin_prior) hide tags: (instructions))
60Show acei/arb options (already taking)(if [med_bp]==1, showHideTags: show tags: (acei_prior) hide tags: (instructions))
61Hide BP warning message by default(if 1==1, showHideTags: hide tags: (bp_warning_message))
62Hide Finerenone message by default(if 1==1, showHideTags: hide tags: (finerenone_warning))
63Show Finerenone message(if (
(((([important_outcome]==6)
||
([important_outcome]==2))
||
([important_outcome]==3))
||
([important_outcome]==0))
&&
(
(parseFloat([ckdepi])>=60)
&&
(parseFloat([acr])<=30)
)), showHideTags: show tags: (finerenone_warning))
64If CVD important then show CVD(if [important_outcome]==1, showHideTags: show tags: (cvd_important))
65If HF important then show HF(if [important_outcome]==2, showHideTags: show tags: (hf_important))
66If kidney important then show kidney(if [important_outcome]==3, showHideTags: show tags: (kidney_important))
67If vision important then show vision(if [important_outcome]==4, showHideTags: show tags: (vision_important))
68If pressure important then show pressure(if [important_outcome]==5, showHideTags: show tags: (pressure_important))
69If death important then show death(if [important_outcome]==0, showHideTags: show tags: (death_important))
70Show all outcomes(if [selected_or_all]==1, showHideTags: show tags: (all_outcomes) hide tags: (cvd_important, hf_important, kidney_important, vision_important, pressure_important, death_important))
71Hide "risk of all outcomes in next 10 years" by default(if 1==1, showHideTags: hide tags: (all_outcomes))
72Show selected outcome vs all outcomes by default(if 1==1, showHideTags: show tags: (selected_or_all))
73Hide selected outcomes vs all outcomes if "everything" selected(if [important_outcome]==6, showHideTags: hide tags: (selected_or_all))
74Show individual outcomes by default(if 1==1, showHideTags: show tags: (single))
75Hide individual outcomes if all outcomes selected(if [single_or_all]==1 || [important_outcome]==6, showHideTags: hide tags: (single))
76Hide all individual outcome messages by default(if 1==1, showHideTags: hide tags: (cvd_important, hf_important, kidney_important, vision_important, pressure_important, death_important))
77Show CVD if important(if [important_outcome]==1, showHideTags: show tags: (cvd_important))
78Show HF if important(if [important_outcome]==2, showHideTags: show tags: (hf_important))
79Show kidney if important(if [important_outcome]==3, showHideTags: show tags: (kidney_important))
80Show vision if important(if [important_outcome]==4, showHideTags: show tags: (vision_important))
81Show pressure if important(if [important_outcome]==5, showHideTags: show tags: (pressure_important))
82Show death if important(if [important_outcome]==0, showHideTags: show tags: (death_important))
83Show "risk of all outcomes in next 10 years" if Step 2 "Everything" or Step 3 "All outcomes"(if [single_or_all]==1 || [important_outcome]==6, showHideTags: show tags: (all_outcomes))
84Hide all individual outcome messages if "all outcomes" selected(if [single_or_all]==1, showHideTags: hide tags: (cvd_important, hf_important, kidney_important, vision_important, pressure_important, death_important))
85If SBP≤120 then disable blood pressure lowering(if [sbp]<=120, performActions: [bp_target_on]->disable)
86If on OAC display ASA disable explanation(if [med_oac]==1, showHideTags: show tags: (asa_disable))
87Only one antihypertensive option can be selected and disable acei/arb as treatment option(if [med_bp]==1, performActions: [med_bp2]->disable, [tx_acei]->disableAlreadyTaking)
88Show BP warning message(if ((([sbp_difference]<0)&&([sbp]>120))&&([bp_target_on]==1)), showHideTags: show tags: (bp_warning_message))
89NOTE: "If not starting bp lowering" page logic does not work, this functionality is built into "ascvd_corrected" and "hf_corrected" instead(if [options_bp]>0, performActions: )
90If not starting sulfonylurea then no benefit(if (parseFloat([options_sulfonylurea])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
91If not starting insulin then no benefit(if (parseFloat([options_insulin])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
92If not starting finerenone then no benefit(if (parseFloat([options_finerenone])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
93If not starting ASA then no benefit(if (parseFloat([options_asa])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
94If not starting ACEI then no benefit(if (parseFloat([options_acei])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
95If not starting ezetimibe then no benefit(if (parseFloat([options_ezetimibe])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
96If not starting statin then no benefit(if (parseFloat([options_statin])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
97If not starting ddp4 then no benefit(if (parseFloat([options_dpp])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
98If not starting metformin then no benefit(if (parseFloat([options_metformin])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
99No glp1 benefit if not starting(if (parseFloat([options_glp])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
100No flozin benefit if not starting(if (parseFloat([options_flozin])==1), setBenefit: rr_death -> 1, rr_ascvd -> 1, rr_ascvd_2o -> 1, rr_hf -> 1, rr_esrd -> 1, rr_esrd_dkd -> 1, rr_retinopathy -> 1, rr_neuropathy -> 1)
101No albuminuria, disable acei/arb(if ([acr]<23)
&&
([important_outcome]==3), performActions: [tx_acei]->disable)