Skip to contents

Plots Tanner pubertal stage measurements for one or more persons against the Dutch 1997 reference curves, expressed as standard deviation scores (SDS) by age.

Usage

plot_stadia(
  data = pub.data,
  persons = unique(data$id),
  plotline = c(TRUE, FALSE, FALSE),
  type = c(TRUE, FALSE, FALSE),
  colors = c("#0060A0", "#00A000", "#A00000"),
  overlay = FALSE,
  ovsex = "M",
  ref = tanner::nl1997_lines,
  title = "Tanner pubertal stages - Patient ",
  padid = TRUE
)

Arguments

data

A data frame with columns id, age, sex and the pubertal stage variables (gen, phb, tv for males; bre, phg, men for females). tv (testicular volume) is the raw reading in **ml** — any value, not just the 12 Prader orchidometer bead volumes (1, 2, 3, 4, 5, 6, 8, 10, 12, 15, 20, 25) — the trajectory is traced along the nearest reference curve. The other stage variables are the integer Tanner stage.

persons

Vector of person identifiers (values of data$id) to plot.

plotline

Logical vector of length 3 indicating which reference lines to draw.

type

Logical vector of length 3 indicating which pubertal stage variables to plot.

colors

Character vector of length 3 with the colors used for the three pubertal stage variables.

overlay

If TRUE, plot all persons on a single graph.

ovsex

Sex ("M" or "F") used to select the reference lines when overlay = TRUE.

ref

Reference data used to draw the reference lines, as produced by nl1997_lines.

title

Plot title.

padid

If TRUE, append the person identifier to the title.

Value

Invisibly returns NULL; the function draws on the current graphics device.