From 4a24a06b92880300e97962748ee25129761410f0 Mon Sep 17 00:00:00 2001 From: nmendiboure Date: Thu, 16 May 2024 12:50:39 +0200 Subject: [PATCH] changed regex pattern for fastq quality filter --- hicstuff/stats.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hicstuff/stats.py b/hicstuff/stats.py index 7c0a704..428d6c8 100644 --- a/hicstuff/stats.py +++ b/hicstuff/stats.py @@ -45,7 +45,7 @@ def get_pipeline_stats(log_file): # 2. Number (% of total) of (un)mapped reads tot_mapped = [s for s in log_lines if re.search("mapped with Q ", s)][0] - tot_mapped = re.sub(".*Q >= 30 \(", "", tot_mapped) + tot_mapped = re.sub(".*Q >= \d+ \(", "", tot_mapped) tot_mapped = re.sub("/.*", "", tot_mapped) tot_mapped = int(float(tot_mapped)) tot_unmapped = fastq_pairs*2 - tot_mapped