posMaskedSeq {GeneR} | R Documentation |
These functions return the position of masked fragments within a sequence. Masked fragments are identified by lower case letters or by specific characters (for example: 'N').
posMaskedSeq(seqno=0,from = 1, to = 0, max = 10000,type= "lower") posMaskedSeqFile(file, name = NA, from = 1, to = 0, max = 10000)
seqno |
Integer/scalar, Sequence number (buffer number) |
from,to |
Integer/vector, Absolute addresses of the begin and the end of the fragments, (1 means the first nucleotide and 0 conventionally the last one; from must not be larger than to) |
file |
String/scalar, Path and file name of the Fasta sequence bank |
name |
Name of the sequence (if NA: the first sequence of the bank) |
type |
type of masked nucleotide i.e. "lower" or any character like "N" (if lower, posMaskedSeq looks for lower case letters; if a character, posMaskedSeq looks for this character |
max |
Maximum number of fragments to retrieve (default: 10000) |
a matrix of size n,2.
gives a warning if there is more than max regions.
return numeric(0) when no regions found.
This function returns by default only 10000 first regions (default parameter max).
Odile Rogier and Antoine Lucas
See also mask
, upperSeq
, lowerSeq
## Make a dummy sequence s <- "ATGCtgTGTTagtacATNNNNNNNNNNNNNNNTGGGTTTaAAAattt" placeString(s,upper=FALSE,seqno=0) posMaskedSeq(seqno=0,type="upper") posMaskedSeq(seqno=0,type="lower") ## Not run: posMaskedSeq(seqno=0,type="lower",max=2) ## End(Not run) posMaskedSeq(seqno=0,type="N") writeFasta(file="toto.fa") posMaskedSeqFile("toto.fa")