Learn R Programming

hiReadsProcessor (version 1.8.2)

findAndRemoveVector: Find and trim vector sequence from reads.

Description

This function facilitates finding and trimming of long/short fragments of vector present in LM-PCR products. The algorithm looks for vector sequence present anywhere within the read and trims according longest contiguous match on either end of the read. Alignment is doing using BLAT

Usage

findAndRemoveVector(reads, Vector, minLength = 10, returnCoords = FALSE,
  parallel = TRUE)

Arguments

reads
DNAStringSet object containing sequences to be trimmed for vector.
Vector
DNAString object containing vector sequence to be searched in reads.
minLength
integer value dictating minimum length of trimmed sequences to return. Default is 10.
returnCoords
return the coordinates of vector start-stop for the matching reads. Defaults to FALSE.
parallel
use parallel backend to perform calculation with BiocParallel. Defaults to TRUE. If no parallel backend is registered, then a serial version is ran using SerialParam.

Value

  • DNAStringSet object with Vector sequence removed from the reads. If returnCoords=TRUE, then a list of two named elements "hits" & "reads". The first element, "hits" is a GRanges object with properties of matched region and whether it was considered valid denoted by 'good.row'. The second element, "reads" is a DNAStringSet object with Vector sequence removed from the reads.

See Also

pairwiseAlignSeqs, vpairwiseAlignSeqs, pslToRangedObject, blatSeqs, read.blast8, findAndTrimSeq