function to calculate the BMI with the standard formulae: \(BMI = weight / (height/100)^2 \)
bmi_calc(height, weight, unit = list(height = "cm", weight = "kg"))
height | height |
---|---|
weight | weight |
unit | list of weight and heigt with units for the measures |
numeric vector of BMI
Other bmi functions:
bmi_calc2()
bmi_calc(176, 72)#> [1] 23.2438