aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
authorGN22020-03-27 19:29:53 -0500
committerGN22020-03-27 19:29:53 -0500
commit12ebdcf0b61d95abed0fd41e91cb0bf5e6898a73 (patch)
tree14feef2921db0a3e17ab70f11fa25aad38a3c7e8 /wqflask
parent8fda0e93cbf10cfcd6f97fd67cb3a175d62cb48d (diff)
parentaa628fb118a92e5df9818619e25dcc5f96f7a889 (diff)
downloadgenenetwork2-12ebdcf0b61d95abed0fd41e91cb0bf5e6898a73.tar.gz
Merge branch 'testing' of https://github.com/genenetwork/genenetwork2 into HEAD
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/wqflask/marker_regression/display_mapping_results.py16
1 files changed, 13 insertions, 3 deletions
diff --git a/wqflask/wqflask/marker_regression/display_mapping_results.py b/wqflask/wqflask/marker_regression/display_mapping_results.py
index cf4508dd..302a4ff9 100644
--- a/wqflask/wqflask/marker_regression/display_mapping_results.py
+++ b/wqflask/wqflask/marker_regression/display_mapping_results.py
@@ -356,7 +356,11 @@ class DisplayMappingResults(object):
self.ChrLengthCMList = []
for i, _chr in enumerate(self.genotype):
- self.ChrLengthCMList.append(_chr[-1].cM - _chr[0].cM)
+ if self.mapping_method == "rqtl_geno" and self.genotype.filler == True:
+ self.ChrLengthCMList.append(_chr[-1].cM)
+ else:
+ self.ChrLengthCMList.append(_chr[-1].cM - _chr[0].cM)
+
self.ChrLengthCMSum = reduce(lambda x, y:x+y, self.ChrLengthCMList, 0.0)
if self.plotScale == 'physic':
@@ -1564,7 +1568,10 @@ class DisplayMappingResults(object):
if self.selectedChr == -1: #ZS: If viewing full genome/all chromosomes
for i, _chr in enumerate(self.genotype):
thisChr = []
- Locus0CM = _chr[0].cM
+ if self.mapping_method == "rqtl_geno" and self.genotype.filler == True:
+ Locus0CM = 0
+ else:
+ Locus0CM = _chr[0].cM
nLoci = len(_chr)
if nLoci <= 8:
for _locus in _chr:
@@ -1586,7 +1593,10 @@ class DisplayMappingResults(object):
for i, _chr in enumerate(self.genotype):
if _chr.name == self.ChrList[self.selectedChr][0]:
thisChr = []
- Locus0CM = _chr[0].cM
+ if self.mapping_method == "rqtl_geno" and self.genotype.filler == True:
+ Locus0CM = 0
+ else:
+ Locus0CM = _chr[0].cM
for _locus in _chr:
if _locus.name != ' - ':
if _locus.cM != preLpos: