aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/base/data_set.py9
-rw-r--r--wqflask/wqflask/show_trait/show_trait.py1
2 files changed, 10 insertions, 0 deletions
diff --git a/wqflask/base/data_set.py b/wqflask/base/data_set.py
index 4cb82665..b8f2f9fb 100644
--- a/wqflask/base/data_set.py
+++ b/wqflask/base/data_set.py
@@ -398,6 +398,15 @@ class DatasetGroup:
if maternal and paternal:
self.parlist = [maternal, paternal]
+ def get_study_samplelists(self):
+ study_sample_file = "%s/study_sample_lists/%s.json" % (webqtlConfig.GENODIR, self.name)
+ try:
+ f = open(study_sample_file)
+ except:
+ return None
+ study_samples = json.load(f)
+ return study_samples
+
def get_genofiles(self):
jsonfile = "%s/%s.json" % (webqtlConfig.GENODIR, self.name)
try:
diff --git a/wqflask/wqflask/show_trait/show_trait.py b/wqflask/wqflask/show_trait/show_trait.py
index c07430dd..d3356bc3 100644
--- a/wqflask/wqflask/show_trait/show_trait.py
+++ b/wqflask/wqflask/show_trait/show_trait.py
@@ -192,6 +192,7 @@ class ShowTrait:
[self.dataset.species.chromosomes.chromosomes[this_chr].name, i])
self.genofiles = self.dataset.group.get_genofiles()
+ self.study_samplelists = self.dataset.group.get_study_samplelists()
# ZS: No need to grab scales from .geno file unless it's using
# a mapping method that reads .geno files