get_BMI_percentile: Calculate youth BMI percentile from CDC standards

View source: R/get_BMI_percentile.R

get_BMI_percentileR Documentation

Calculate youth BMI percentile from CDC standards

Description

Calculate youth BMI percentile from CDC standards

Usage

get_BMI_percentile(
  weight_kg,
  height_cm,
  age_yrs = NULL,
  age_mos = NULL,
  sex = c("Male", "Female"),
  BMI = NULL,
  df = NULL,
  output = c("percentile", "classification", "both", "summary")
)

percentile_df(
  df,
  weight_kg = "default",
  height_cm = "default",
  age_yrs = "default",
  age_mos = "default",
  sex = "default",
  BMI = "default",
  output = c("percentile", "classification", "both", "summary")
)

Arguments

weight_kg

Weight in kilograms

height_cm

height in centimeters

age_yrs

age in years

age_mos

age in months (optional)

sex

Character scalar indicating participant's sex

BMI

numeric. Body mass index

output

What should be returned: raw percentile, weight status classification, both percentile and classification, or a full summary (BMI, percentile, classification, and severe obesity cutoff)?

df.

Optional data frame on which to operate. Default is NULL. If passed, the preceding arguments that have been documented on this page (weight_kg, height_cm, etc) are expected to be character scalars naming the columns of df in which the that information can be found

Details

Only one of age_mos and age_yrs is required. The former will be used if both are provided. If age_mos is not provided, it will be calculated based on age_yrs, assuming 365.2425 days per year and 30.4375 days per month. Depending on how the initial age calculation was made, rounding error will occur. Thus, use of the get_age function is recommended, with units = "months". If BMI is provided, there is no need to pass weight_kg or height_cm.

Value

One of: A numeric scalar giving the BMI percentile (for output = "percentile"); a factor scalar giving the weight status (for output = "classification"); a list with the percentile and classification (for output = "both"); or a list with the BMI, percentile, classification, and severe obesity cutoff (for output = "summary").

References

This function was developed with reference to public domain resources provided by the Centers for Disease Control and Prevention. For more information, see:

https://www.cdc.gov/obesity/childhood/defining.html

https://www.cdc.gov/healthyweight/assessing/bmi/childrens_bmi/tool_for_schools.html

See Also

Flegal et al. (2009) Kelly et al. (2013)

Examples

get_BMI_percentile(39.4, 144.5, 12.35, sex = "Male")

PAutilities documentation built on Aug. 21, 2022, 9:05 a.m.