From 9503e6c819593cdb6c82f73472858e992db45003 Mon Sep 17 00:00:00 2001 From: jemten Date: Mon, 13 Feb 2023 17:34:37 +0100 Subject: [PATCH] fixing MT deletetion calculation, fixes #2016 --- CHANGELOG.md | 4 ++++ lib/MIP/Constants.pm | 2 +- lib/MIP/Recipes/Analysis/Mitodel.pm | 9 ++++++--- templates/mip_install_config.yaml | 2 +- 4 files changed, 12 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 305ec7aa5..52d1187a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,10 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [11.1.2] + +- Fixed a bug in the mitochondrial deletion recipe affecting samples with 0 intermediate discordant MT reads. + ## [11.1.1] - Updates chromgraph to version 1.3.1 diff --git a/lib/MIP/Constants.pm b/lib/MIP/Constants.pm index 71547bd02..8f8c7e6ad 100644 --- a/lib/MIP/Constants.pm +++ b/lib/MIP/Constants.pm @@ -82,7 +82,7 @@ Readonly our %ANALYSIS => ( ); ## Set MIP version -Readonly our $MIP_VERSION => q{11.1.1}; +Readonly our $MIP_VERSION => q{11.1.2}; ## Cli Readonly our $MOOSEX_APP_SCEEN_WIDTH => 160; diff --git a/lib/MIP/Recipes/Analysis/Mitodel.pm b/lib/MIP/Recipes/Analysis/Mitodel.pm index 0729f16f3..6f2563f40 100644 --- a/lib/MIP/Recipes/Analysis/Mitodel.pm +++ b/lib/MIP/Recipes/Analysis/Mitodel.pm @@ -230,14 +230,17 @@ sub analysis_mitodel { my $awk_statement = + # Set start value for intermediate discordant + q?BEGIN {sum=0} ? + # identification of read pairs that are separated by >1.2 kb but <15 kb - q?($2>=1200 && $2<=15000) {sum=sum+$3}? + . q?($2>=1200 && $2<=15000) {sum=sum+$3} ? # identification of normal read pairs which are <1.2 kb but >15 kb - . q?($2<1200 || $2>15000) {sum_norm=sum_norm+$3}? + . q?($2<1200 || $2>15000) {sum_norm=sum_norm+$3} ? # Add end rule - . q?END? + . q?END ? # ratio of discordant to normal read pairs . q?{print "intermediate discordant ", sum, "normal ", sum_norm, "ratio ppk", sum*1000/(sum_norm+sum)}?; diff --git a/templates/mip_install_config.yaml b/templates/mip_install_config.yaml index f25b6ddb6..e7dfd3d77 100644 --- a/templates/mip_install_config.yaml +++ b/templates/mip_install_config.yaml @@ -125,7 +125,7 @@ container: mip: executable: mip: - uri: docker.io/clinicalgenomics/mip:v11.1.1 + uri: docker.io/clinicalgenomics/mip:v11.1.2 multiqc: executable: multiqc: