|
|
@@ -29,7 +29,8 @@ pub struct Cases {
|
|
|
}
|
|
|
|
|
|
impl Cases {
|
|
|
- pub fn load(mp: MultiProgress) -> Result<Self> {
|
|
|
+ pub fn load(mp: MultiProgress, skip_ids: Option<Vec<String>>) -> Result<Self> {
|
|
|
+ let ids_to_skip = skip_ids.unwrap_or(vec![]);
|
|
|
let config = Config::get()?;
|
|
|
let mut diag_bams = HashMap::new();
|
|
|
for entry in glob(&config.diag_bam_glob).context("Failed to read glob pattern")? {
|
|
|
@@ -70,6 +71,9 @@ impl Cases {
|
|
|
let mut cases = Vec::new();
|
|
|
let diff_snp = DiffSnp::init(&config.commun_snp)?;
|
|
|
for (id, diag_bam) in diag_bams {
|
|
|
+ if ids_to_skip.contains(&id) {
|
|
|
+ continue;
|
|
|
+ }
|
|
|
if let Some(mrd_bam) = mrd_bams.get(&id) {
|
|
|
// verify if both samples match commun snps
|
|
|
let diff = diff_snp.diff_prop(diag_bam.path.to_str().unwrap(), mrd_bam.path.to_str().unwrap())?;
|