sequences2transmatrix | R Documentation |
Calculates the transition matrix by counting occurrences of tuples in given vector list
sequences2transmatrix(sequences)
sequences |
Sequences to be analyzed, can be a list of vectors, or a vector |
In output, score_value is coerced as integer if possible. Else, it is a character vector containing the states of the Markov chain.
A list object containing
transition_matrix |
Transition Matrix with row names and column names are the associated score/state |
score_value |
a vector containing the score/state, ordered in the same way as the matrix columns and rows |
myseq <- sample(LETTERS[1:2], size=20,replace=TRUE)
sequences2transmatrix(myseq)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.