Skip to content

Commit

Permalink
fixed rev math
Browse files Browse the repository at this point in the history
  • Loading branch information
lskatz committed Jan 4, 2025
1 parent c1a5905 commit f9d9a94
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/bin/fasten_trim.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@
//! # Output
//!
//! The deflines will be altered with a description of the trimming in brackets, e.g.,
//! [trimmed_adapter_rev=TT] [trimmed_left=0] [trimmed_right=250]
//! `@M03235:53:000000000-AHLTD:1:1101:1826:14428 [trimmed_adapter_rev=TT] [trimmed_left=0] [trimmed_right=249]`
//! or for a forward adapter,
//! `@M03235:53:000000000-AHLTD:1:1101:1758:14922 [trimmed_adapter_fwd=AA] [trimmed_left=2] [trimmed_right=251]`
extern crate fasten;
extern crate statistical;
Expand Down Expand Up @@ -242,7 +244,7 @@ fn trim_worker(seq:Seq, suggested_first_base:usize, suggested_last_base:usize, a
last_base = seq.seq.len()-1;
}

description.push_str(&format!(" [trimmed_left={}] [trimmed_right={}]", first_base, last_base));
description.push_str(&format!(" [trimmed_left={}] [trimmed_right={}]", first_base, last_base-1));

let sequence = &seq.seq[first_base..last_base];
let quality = &seq.qual[first_base..last_base];
Expand Down

0 comments on commit f9d9a94

Please sign in to comment.