seqVectorAlphabetFrequency {XNAString} | R Documentation |
seqVectorAlphabetFrequency function calculates frequency for strings vector
seqVectorAlphabetFrequency(unique_letters, seq_vec, as.prob)
unique_letters |
string (or character) - these letters pose column names |
seq_vec |
vector of strings (or characters) - frequency will be calculated for this vector |
as.prob |
logical - if TRUE frequency returned as probability of occurence |
matrix - each row denotes frequency for a specific string of vector
seqVectorAlphabetFrequency(c("A", "B", "C"), c("AABA", "BBBCCC"), as.prob = FALSE )