Description Usage Arguments Examples
This function obtains the flanking sequence at one or more position. Out of bound indices are replaced by a blank character.
1 | flankingSequence(seqs, inds, flank = 7, empty_char = "-")
|
seqs |
Character vector of sequences. If only one sequence is provided,
indices from |
inds |
Numerical vector of positions corresponding to the sequences provided in |
flank |
Value indicating the number of characters to extract, before and after an index |
empty_char |
Character used to replace out of bound flanking sequences |
1 2 3 4 5 6 | # One sequence and one index. Central character is 'B'
flankingSequence(seqs='ABC', inds=2, flank=1)
# An example showing the use of empty.char
flankingSequence(seqs='ABC', inds=2, flank=5)
# An example with multiple sequences and indices
flankingSequence(seqs=c('ABC', 'XYZ'), inds=c(2, 1), flank=1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.