Convert a character string into a vector of states or events
For the moment, each character in the string will be considered to be one state or event = this function will not give accurate results if the character string representing the sequence contains events or states coded with more than one character.
seqdecomp(data, var=NULL, sep='-', miss="NA", vnames=NULL)
data |
a dataframe or matrix containing sequence data. |
var |
the list of columns containing the sequences. Default is |
sep |
the between states/events separator used in the input data set. Default is ' |
miss |
the symbol for missing values (if any) used in the input data set. Default is |
vnames |
optional names for the column/variables of the output data set. Default is |
## Converts 'seq' into a vector of states of length 10 seq <- "A-A-A-A-B-B-B-C-C-C" seqdecomp(seq)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.