Learn R Programming

cliot (version 1.0.0)

estimated_peak_flow: Estimated/Expected Peak Expiratory Flow (Peak Flow) - NHANES III

Description

Calculates the estimated Peak Expiratory Flow (PEF) rate based on the Hankinson et al. (1999) equations derived from the Third National Health and Nutrition Examination Survey (NHANES III). These equations stratify by age, sex, and race/ethnicity (Caucasian, African-American, Mexican-American) and use height and age polynomial regression models.

Usage

estimated_peak_flow(age, height_in, sex, race, actual_pef = NULL)

Value

A list containing:

Estimated_PEF_L_min

The predicted Peak Expiratory Flow rate in Liters per minute.

Percent_Predicted

The ratio of the actual measured PEF to the estimated PEF (if actual_pef is provided).

Method

Citation of the formula source (Hankinson 1999).

Arguments

age

Numeric. Patient age in years (Valid range: 8-80).

height_in

Numeric. Patient height in inches.

sex

String. Patient sex ("Male" or "Female").

race

String. Patient race/ethnicity ("White", "Black", "Hispanic", or "Other"). "Other" uses the Caucasian/White equation coefficients.

actual_pef

Numeric (Optional). The patient's actual measured PEF in L/min. If provided, the function calculates the percent of predicted value.

References

Hankinson JL, Odencrantz JR, Fedan KB. Spirometric reference values from a sample of the general U.S. population. Am J Respir Crit Care Med. 1999;159(1):179-187. doi:10.1164/ajrccm.159.1.9712108

Examples

Run this code

# Example 1: Adult Male
# 45 years old, 70 inches (178 cm), White
# Estimated PEF: ~580-600 L/min depending on exact coeff
estimated_peak_flow(45, 70, "male", "white")

# Example 2: Child with Actual Reading
# 10 years old, 55 inches (140 cm), Black, Measured PEF 300
# Returns Estimated and % Predicted
estimated_peak_flow(10, 55, "male", "black", actual_pef = 300)

Run the code above in your browser using DataLab