diff options
author | Zachary Sloan | 2013-06-26 21:35:07 +0000 |
---|---|---|
committer | Zachary Sloan | 2013-06-26 21:35:07 +0000 |
commit | 6fbbfe5e8bcc3b57c4177687bbf67bf041da3cba (patch) | |
tree | 80b2b5252f3bfb42a8f01e2df2c27a5a21cbbb7b /wqflask/base/species.py | |
parent | d703c6e456334187a279c04e9b4cf6a8e5099785 (diff) | |
download | genenetwork2-6fbbfe5e8bcc3b57c4177687bbf67bf041da3cba.tar.gz |
Got code that creates DataSets object running
Fixed one genofile that had extra quotation marks
in the comments that caused an error
Defaults mb_graph_interval to 1 for species without chromosome
lengths in megabases
Diffstat (limited to 'wqflask/base/species.py')
-rw-r--r-- | wqflask/base/species.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/wqflask/base/species.py b/wqflask/base/species.py index 191f4535..ebc2bfed 100644 --- a/wqflask/base/species.py +++ b/wqflask/base/species.py @@ -56,6 +56,7 @@ class Chromosomes(object): InbredSet.Name = %s Order by OrderId """, self.dataset.group.name).fetchall() + print("group: ", self.dataset.group.name) print("bike:", results) for item in results: @@ -68,9 +69,14 @@ class Chromosomes(object): def set_mb_graph_interval(self): """Empirical megabase interval""" + if self.chromosomes: + self.mb_graph_interval = self.get_genome_mb_length()/(len(self.chromosomes)*12) + else: + self.mb_graph_interval = 1 + #if self.chromosomes: - assert self.chromosomes, "Have to add some code back in apparently to set it to 1" - self.mb_graph_interval = self.get_genome_mb_length()/(len(self.chromosomes)*12) + #assert self.chromosomes, "Have to add some code back in apparently to set it to 1" + #self.mb_graph_interval = self.get_genome_mb_length()/(len(self.chromosomes)*12) #else: #self.mb_graph_interval = 1 |