Learn R Programming

childsds (version 0.6)

make_percentile_tab: calculate raw values

Description

Calculate raw values for percentile curve

Usage

make_percentile_tab(refs, item, perc = c(1, 5, 50, 95, 99), stack = F, sex,
  age)

Arguments

refs
Refgroup object
item
name of the measurement item
perc
vector of percentiles to be calculated
stack
wether or not the data should be stacked, stacked data would most possibly be used in ggplot2
sex
name of the sex variable (character) if different from sex, ignored
age
name of the age variable (character) if different from age, ignored

Value

data frame either with the different percentiles as columns or, if stacked, as data frame with four columns: age, sex, variable, value

Details

calculates quantile values for given RefGroup and given percentiles