trim_to_min_quality

Function trim_to_min_quality 

Source
pub fn trim_to_min_quality<'a>(
    seq: &'a [u8],
    qual: &[u8],
    min_q: u8,
) -> Option<&'a [u8]>
Expand description

Trim leading and trailing low-quality bases using a sliding-window average.

Scans inward from each end with a window of [WINDOW] bases; the first window position (from each end) whose mean Phred quality ≥ min_q defines the trim boundary. Falls back to single-base scan when seq is shorter than the window. Returns None when no region meets the threshold.