Description Usage Arguments Details Author(s) Examples
Takes an existing Lexis grid and adds a coloured rectangle to highlight a certain cohort.
1 | lexis.cohort(lg, cohort, fill = lpr_colours()[4], alpha = 0.7, d = 1)
|
lg, |
an existing object originally created with |
cohort |
numeric, set the cohort to highlight. |
fill |
character, set the colour of the rectangle. Default is |
alpha |
numeric, set the level of transparency of the rectangle. Default is |
d |
numeric, set the size of the age groups. Default is 1. |
Takes an existing Lexis grid and adds a coloured rectangle to the plot. The rectangle will highlight a certain cohort in the Lexis grid.
Philipp Ottolinger
1 2 3 4 5 6 | ## Not run:
library(LexisPlotR)
lg <- lexis.grid(year.start = 1900, year.end = 1905, age.start = 0, age.end = 5)
lexis.cohort(lg = lg, cohort = 1901)
## End(Not run)
|
Loading required package: ggplot2
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.