Description Usage Arguments Details Value Author(s) Examples
Produces a frequency table of the state sequences recorded in the data. The mean or median ages at transition are computed.
1 | Sequences(Bdata,mean_median)
|
Bdata |
Biograph object |
mean_median |
Select mean or median age: "mean" or "median" |
The sequences are determined from the path variable in the data. The default age is the median age.
Frequency table of sequences
Frans Willekens
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | # Example 1: Sequences in GLHS
data(GLHS)
z <- Parameters (GLHS)
seq <- Sequences (Bdata=GLHS,mean_median="median")
# Example 2: Sequences in NLOG98
data(NLOG98)
z <- Parameters (NLOG98)
seq <- Sequences (NLOG98) # default is median age
# Example 3: State sequence in NLOG98, by birth cohort
table(NLOG98$cohort) # cohort size
seq.1 <- Sequences(NLOG98[NLOG98$cohort=="<1960",],"median")
seq.2 <- Sequences(NLOG98[NLOG98$cohort=="1960+",],"median")
# Note that the sum(seq.2$ncase) equals size of second cohort
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.