Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 921a9b1

Browse files
committedNov 13, 2024
commands/describe: Actually track min and max sequence lengths
c5af096 added fields for these but didn't actually track them.
1 parent 695689e commit 921a9b1

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed
 

‎src/commands/describe.rs

+6-1
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,13 @@ impl Default for Metrics {
3636
}
3737
}
3838

39-
fn visit(metrics: &mut Metrics, _: &Record) {
39+
fn visit(metrics: &mut Metrics, record: &Record) {
4040
metrics.record_count += 1;
41+
42+
let read_length = record.sequence().len();
43+
44+
metrics.min_sequence_length = metrics.min_sequence_length.min(read_length);
45+
metrics.max_sequence_length = metrics.max_sequence_length.max(read_length);
4146
}
4247

4348
fn print_metrics(metrics: &Metrics) {

0 commit comments

Comments
 (0)
Please sign in to comment.