# Example 1: Normal Status
# Albumin 4.5 g/dL (45 g/L), Weight stable (Ratio 1)
# Score = (1.519 * 45) + 41.7 = 68.355 + 41.7 = 110.1
nri_score(4.5, 70, 70)
# Example 2: Severe Risk
# Albumin 2.5 g/dL (25 g/L), Significant weight loss (55/70 = 0.785)
# Score = (1.519 * 25) + (41.7 * 0.785) = 37.975 + 32.73 = 70.7
nri_score(2.5, 55, 70)
Run the code above in your browser using DataLab