From 704df5e1a4b908edbdc3d7cb6d309889a230b1c9 Mon Sep 17 00:00:00 2001 From: "tobias.neumann" Date: Fri, 8 Feb 2019 21:47:22 +0100 Subject: [PATCH] Bugfix: Reverse strand A->G SNP coordinates. --- slamdunk/utils/SNPtools.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/slamdunk/utils/SNPtools.py b/slamdunk/utils/SNPtools.py index 10d59c2..0ba4778 100644 --- a/slamdunk/utils/SNPtools.py +++ b/slamdunk/utils/SNPtools.py @@ -28,12 +28,13 @@ def __init__(self, vcfFile): self._agSNPs = {} def _addSNP(self, snp): + if(snp[3].upper() == "T" and snp[4].upper() == "C"): key = snp[0] + snp[1] self._tcSNPs[key] = True if(snp[3].upper() == "A" and snp[4].upper() == "G"): - key = snp[0] + str(int(snp[1]) - 1) + key = snp[0] + snp[1] self._agSNPs[key] = True def read(self):