Returns a matrix with transition rates between states, computed from a set of sequences.
1 2 
seqdata 
a sequence object as defined by the 
statl 
a list of states or events for which the transition rates will be computed. If omitted (default), transition rates are computed between the distinct states in seqdata (obtained with the 
time.varying 
Logical. If 
weighted 
Logical. If 
lag 
Integer. Time between the two states considered to compute transition rates (one by default). 
with.missing 
Logical. If 
Transition rates are the probabilities of transition from one state to another observed in the sequence data. Substitution costs based on transition rates can be used when computing distances between sequences with the optimal matching method (see seqdist).
a matrix of dimension ns*ns, where ns is the number of states in the alphabet of the sequence object.
Matthias Studer and Alexis Gabadinho (first version) (with Gilbert Ritschard for the help page)
Gabadinho, A., G. Ritschard, N. S. M<fc>ller and M. Studer (2011). Analyzing and Visualizing State Sequences in R with TraMineR. Journal of Statistical Software 40(4), 137.
seqdist
seqsubm
alphabet
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21  ## Loading the 'actcal' example data set
data(actcal)
## Defining a sequence object with data in columns 13 to 24
## (activity status from january to december 2000)
actcal.seq < seqdef(actcal,13:24,informat='STS')
## Computing transition rates
seqtrate(actcal.seq)
## Computing transition rates between states "A" and "B" only
seqtrate(actcal.seq, c("A","B"))
## ====================
## Example with weights
## ====================
data(ex1)
ex1.seq < seqdef(ex1,1:13, weights=ex1$weights)
seqtrate(ex1.seq, weighted=FALSE)
seqtrate(ex1.seq, weighted=TRUE)

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.
All documentation is copyright its authors; we didn't write any of that.