Learn R Programming

Biograph (version 1.0)

Lexispoints: Plot observations in Lexis diagram

Description

Plots observations in age-time diagram for each category of categorical covariate

Usage

Lexispoints(data, transition, title1, cov)

Arguments

data
Biograph object
transition
The transition selected, e.g. "NJ" in GLHS data
title1
Title of Lexis diagram
cov
Covariate. Observations are plotted for each category of this covariate. If observations should be plotted for the total sample population, cov = NA

Value

  • LcohLexis object created to plot the observations

References

For Lexis diagram, see Carstensen (2009) and the Epi pacakge

See Also

Lexislines.episodes

Examples

Run this code
#  Example 1: ages at labour market entry, by sex
  library (Epi)
  data(GLHS)
  y <- Parameters(GLHS)
  z <- Lexispoints (GLHS,"NJ","Calendar time and age at labour market entry","sex")

#  Example 2: ages at first birth among married women, by religious denomination
  data(NLOG98)
  y <- Parameters (NLOG98)
  z <- Lexispoints (NLOG98,"MK","Calendar time and age at first birth (married women)","kerk")
#  Example 3: ages at leaving home, by birth cohort (any destination)
  z <- Lexispoints (NLOG98,"H*","Calendar time and age at leaving parental home","cohort")

Run the code above in your browser using DataLab