Description Slots Author(s) See Also Examples
The individualAN
class stores anthropometric measures as
the collection of xyz
-class for height, weight,
head circumference, bmi, and weight for height.
hgt
Length/height in cm (xyz
)
wgt
Weight in kg (xyz
)
hdc
Head circumference in cm (xyz
)
wfh
Weight for height kg/m (xyz
)
bmi
Body mass index kg/m**2 (xyz
)
dsc
D-score (D) (xyz
)
Stef van Buuren 2016-2020
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | # create object with height and weight measures
# do not calculate Z-scores since reference is undefined (no sex)
z <- new("individualAN",
hgt = new("xyz", yname = "hgt", x = c(0, 0.5), y = c(50, 70), verbose = TRUE),
wgt = new("xyz", yname = "wgt", x = c(0, 0.3), y = c(3, 6), verbose = TRUE))
data.frame(z)
# specify sex, and we get a reference
z <- new("individualAN",
hgt = new("xyz", yname = "hgt", x = c(0, 0.5), y = c(50, 70), sex = "male"),
wgt = new("xyz", yname = "wgt", x = c(0, 0.3), y = c(3, 6), sex = "male"))
data.frame(z)
# calculate -2 and +2 centiles for height and head circumference
# using the WHO Child Growth Standard for girls
hgtref <- "who_2006_hgt_female_"
hdcref <- "who_2007_hdc_female_"
z <- new("individualAN",
hgt = new("xyz", yname = "hgt", x = c(0, 0, 0.25, 0.25),
z = c(-2, 2, -2, 2), refcode = hgtref, pkg = "centile"),
hdc = new("xyz", yname = "wgt", x = c(0, 0, 0.25, 0.25),
z = c(-2, 2, -2, 2), refcode = hdcref, pkg = "centile"))
data.frame(z)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.