powered by
maskSeqGaps substitutes gap characters, c("-", "."), with "N" in a vector of DNA sequences.
maskSeqGaps
c("-", ".")
"N"
maskSeqGaps(seq, mask_char = "N", outer_only = FALSE)
A modified seq vector with "N" in place of c("-", ".")
seq
characters.
character vector of DNA sequence strings.
character to use for masking.
if TRUE replace only contiguous leading and trailing gaps; if FALSE replace all gap characters.
TRUE
FALSE
See maskSeqEnds for masking ragged edges.
# Mask with Ns maskSeqGaps(c("ATG-C", "CC..C")) maskSeqGaps("--ATG-C-") maskSeqGaps("--ATG-C-", outer_only=TRUE) # Mask with dashes maskSeqGaps(c("ATG-C", "CC..C"), mask_char="-")
Run the code above in your browser using DataLab