diff options
author | Artem Tarasov | 2015-06-18 20:05:49 +0300 |
---|---|---|
committer | Artem Tarasov | 2015-06-18 20:05:49 +0300 |
commit | 45ebe51fbee7da1617b01cff7b9ab404d6ad1aa7 (patch) | |
tree | 33e2e5a0de9f080db3fb9a38e77aa318637a034a /wqflask/base/data_set.py | |
parent | e4621a2a759f55659b5c631baec5e5f497e0cff1 (diff) | |
download | genenetwork2-45ebe51fbee7da1617b01cff7b9ab404d6ad1aa7.tar.gz |
fix all_samples_ordered
move duplicated code into a method,
handle the case of missing f1/f12 correctly
Diffstat (limited to 'wqflask/base/data_set.py')
-rwxr-xr-x | wqflask/base/data_set.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/wqflask/base/data_set.py b/wqflask/base/data_set.py index acfee3d4..b17396e5 100755 --- a/wqflask/base/data_set.py +++ b/wqflask/base/data_set.py @@ -392,6 +392,12 @@ class DatasetGroup(object): Redis.set(key, json.dumps(self.samplelist)) Redis.expire(key, 60*5) + def all_samples_ordered(self): + result = [] + lists = (self.parlist, self.f1list, self.samplelist) + [result.extend(l) for l in lists if l] + return result + def read_genotype_file(self): '''Read genotype from .geno file instead of database''' #if self.group == 'BXD300': |