This function identifies off-target amplification products based on length criteria and quality thresholds. It categorizes sequences as either "too_short" or "too_long".
detect_offtargets(
reads_df,
expected_length = 400,
length_tolerance = 50,
max_dimer_length = 100
)A list with two logical vectors: too_short and too_long, indicating which reads fall into each category. Sequences shorter than max_dimer_length are not included in too_short as they are considered primer dimers.