def trimmed(self, read): index = quality_trim_index(read.qualities, self.cutoff, self.base) self.trimmed_bases += len(read.qualities) - index return read[:index]
def __call__(self, read, matches): start, stop = quality_trim_index(read.qualities, self.cutoff_front, self.cutoff_back, self.base) self.trimmed_bases += len(read) - (stop - start) return read[start:stop]
def __call__(self, read): start, stop = quality_trim_index(read.qualities, self.cutoff_front, self.cutoff_back, self.base) self.trimmed_bases += len(read) - (stop - start) return read[start:stop]