aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzsloan2020-10-29 15:58:16 -0500
committerzsloan2020-10-29 15:58:16 -0500
commit00f7aed2f2da165314bacf33b8fb16d00fc8ec26 (patch)
tree4da40a000d14aaed63d3bba7b4ae28fed530a09c
parent7c1c9e2a519ba662e9f293eea73eb7922b2160e4 (diff)
downloadgenenetwork2-00f7aed2f2da165314bacf33b8fb16d00fc8ec26.tar.gz
Fixed issue with single-chromosome mapping after the bootstrap fix and fixed error that occurred if either bootstrap or permutations were set to 0
* wqflask/wqflask/marker_regression/display_mapping_results.py - Cast self.qtlresults 'chr' as a string since the comparison between it and the chromosome names was faililng due to numeric chromosomes being int type + used a list comprehension that converts None to an empty string when creating a comma-joined string from the list of mapping output files
-rw-r--r--wqflask/wqflask/marker_regression/display_mapping_results.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/wqflask/wqflask/marker_regression/display_mapping_results.py b/wqflask/wqflask/marker_regression/display_mapping_results.py
index 2fc633aa..7e43f6bd 100644
--- a/wqflask/wqflask/marker_regression/display_mapping_results.py
+++ b/wqflask/wqflask/marker_regression/display_mapping_results.py
@@ -342,7 +342,7 @@ class DisplayMappingResults(object):
if 'reaper_version' in list(start_vars.keys()) and self.mapping_method == "reaper":
self.reaper_version = start_vars['reaper_version']
if 'output_files' in start_vars:
- self.output_files = ",".join(start_vars['output_files'])
+ self.output_files = ",".join([(the_file if the_file is not None else "") for the_file in start_vars['output_files']])
self.categorical_vars = ""
self.perm_strata = ""
@@ -752,7 +752,7 @@ class DisplayMappingResults(object):
BootChrCoord.append([Xc, self.bootResult[i]])
else:
for i, result in enumerate(self.qtlresults):
- if result['chr'] == self.ChrList[self.selectedChr][0]:
+ if str(result['chr']) == str(self.ChrList[self.selectedChr][0]):
if self.plotScale == 'physic':
Xc = startX + (result['Mb']-self.startMb)*plotXScale
else: