aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
Diffstat (limited to 'wqflask')
-rwxr-xr-xwqflask/wqflask/show_trait/show_trait.py5
-rwxr-xr-xwqflask/wqflask/templates/show_trait_mapping_tools.html2
2 files changed, 4 insertions, 3 deletions
diff --git a/wqflask/wqflask/show_trait/show_trait.py b/wqflask/wqflask/show_trait/show_trait.py
index d38da8e8..f3a5b0ad 100755
--- a/wqflask/wqflask/show_trait/show_trait.py
+++ b/wqflask/wqflask/show_trait/show_trait.py
@@ -92,7 +92,8 @@ class ShowTrait(object):
#Get nearest marker for composite mapping
- if self.this_trait.locus_chr != "" and self.dataset.type != "Geno" and self.dataset.type != "Publish":
+ print("self.dataset.type:", self.dataset.type)
+ if hasattr(self.this_trait, 'locus_chr') and self.this_trait.locus_chr != "" and self.dataset.type != "Geno" and self.dataset.type != "Publish":
self.nearest_marker1 = get_nearest_marker(self.this_trait, self.dataset)[0]
self.nearest_marker2 = get_nearest_marker(self.this_trait, self.dataset)[1]
@@ -109,7 +110,7 @@ class ShowTrait(object):
hddn['suggestive'] = 0
hddn['num_perm'] = 0
hddn['manhattan_plot'] = False
- if self.this_trait.locus_chr != "" and self.dataset.type != "Geno" and self.dataset.type != "Publish":
+ if hasattr(self.this_trait, 'locus_chr') and self.this_trait.locus_chr != "" and self.dataset.type != "Geno" and self.dataset.type != "Publish":
hddn['control_marker'] = self.nearest_marker1+","+self.nearest_marker2
else:
hddn['control_marker'] = ""
diff --git a/wqflask/wqflask/templates/show_trait_mapping_tools.html b/wqflask/wqflask/templates/show_trait_mapping_tools.html
index 299c3e0c..1d0d4c66 100755
--- a/wqflask/wqflask/templates/show_trait_mapping_tools.html
+++ b/wqflask/wqflask/templates/show_trait_mapping_tools.html
@@ -13,7 +13,7 @@
<a href="#rqtl_geno" data-toggle="tab">rqtl</a>
</li>
{% if dataset.group.species == 'human' %}
- <li>self.this_trait.locus_chr != "" and
+ <li>
<a href="#plink" data-toggle="tab">PLINK</a>
</li>
<li>