|
|
@@ -605,8 +605,13 @@ pub fn somatic_depth_quality_ranges(
|
|
|
let mut line_no = 0usize;
|
|
|
|
|
|
loop {
|
|
|
- let n_ok = n_tsv.read_byte_record(&mut n_rec)?;
|
|
|
- let t_ok = t_tsv.read_byte_record(&mut t_rec)?;
|
|
|
+ let n_ok = n_tsv.read_byte_record(&mut n_rec).with_context(|| {
|
|
|
+ format!("reading normal TSV: {} line {}", normal_path, line_no + 1)
|
|
|
+ })?;
|
|
|
+
|
|
|
+ let t_ok = t_tsv.read_byte_record(&mut t_rec).with_context(|| {
|
|
|
+ format!("reading tumor TSV: {} line {}", tumor_path, line_no + 1)
|
|
|
+ })?;
|
|
|
|
|
|
if n_ok || t_ok {
|
|
|
line_no += 1;
|
|
|
@@ -992,7 +997,7 @@ mod tests {
|
|
|
test_init();
|
|
|
let config = Config::default();
|
|
|
|
|
|
- let id = "DUMCO";
|
|
|
+ let id = "CML2518";
|
|
|
|
|
|
let (mut high_depth_ranges, mut low_quality_ranges) =
|
|
|
somatic_depth_quality_ranges(id, &config)?;
|
|
|
@@ -1002,7 +1007,6 @@ mod tests {
|
|
|
// let high_depth_ranges = merge_adjacent_ranges(high_depth_ranges);
|
|
|
// let low_quality_ranges = merge_adjacent_ranges(low_quality_ranges);
|
|
|
|
|
|
-
|
|
|
info!(
|
|
|
"High-depth ranges: n={} bp={}\nLowQ ranges: n={} bp={}",
|
|
|
high_depth_ranges.len(),
|
|
|
@@ -1010,8 +1014,14 @@ mod tests {
|
|
|
low_quality_ranges.len(),
|
|
|
low_quality_ranges.total_len(),
|
|
|
);
|
|
|
- high_depth_ranges.iter().take(10).for_each(|e| println!("{e:?}"));
|
|
|
- low_quality_ranges.iter().take(10).for_each(|e| println!("{e:?}"));
|
|
|
+ high_depth_ranges
|
|
|
+ .iter()
|
|
|
+ .take(10)
|
|
|
+ .for_each(|e| println!("{e:?}"));
|
|
|
+ low_quality_ranges
|
|
|
+ .iter()
|
|
|
+ .take(10)
|
|
|
+ .for_each(|e| println!("{e:?}"));
|
|
|
Ok(())
|
|
|
}
|
|
|
}
|