diff options
author | Zachary Sloan | 2013-06-20 22:20:23 +0000 |
---|---|---|
committer | Zachary Sloan | 2013-06-20 22:20:23 +0000 |
commit | 4ffee373494170e708678039dca132f1bd729ab1 (patch) | |
tree | a9d6054380f5a9d612a4d1d88889f68ea4923a75 /wqflask/base/species.py | |
parent | 939058c4a3b668037974f2876b072c4be008da26 (diff) | |
parent | 52ac4b6e1c014801080cbbcad53df868058d2657 (diff) | |
download | genenetwork2-4ffee373494170e708678039dca132f1bd729ab1.tar.gz |
Merge branch 'flask'
Diffstat (limited to 'wqflask/base/species.py')
-rw-r--r-- | wqflask/base/species.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/wqflask/base/species.py b/wqflask/base/species.py index 9d4cac4c..191f4535 100644 --- a/wqflask/base/species.py +++ b/wqflask/base/species.py @@ -16,8 +16,7 @@ class TheSpecies(object): print("self.dataset is:", pf(self.dataset.__dict__)) self.chromosomes = Chromosomes(self.dataset) self.genome_mb_length = self.chromosomes.get_genome_mb_length() - - + #@property #def chromosomes(self): # chromosomes = [("All", -1)] @@ -31,7 +30,8 @@ class TheSpecies(object): # return chromosomes class IndChromosome(object): - def __init__(self, length): + def __init__(self, name, length): + self.name = name self.length = length @property @@ -50,7 +50,7 @@ class Chromosomes(object): results = g.db.execute(""" Select - Chr_Length.Name, Length from Chr_Length, InbredSet + Chr_Length.Name, Chr_Length.OrderId, Length from Chr_Length, InbredSet where Chr_Length.SpeciesId = InbredSet.SpeciesId AND InbredSet.Name = %s @@ -59,10 +59,10 @@ class Chromosomes(object): print("bike:", results) for item in results: - self.chromosomes[item.Name] = IndChromosome(item.Length) + self.chromosomes[item.OrderId] = IndChromosome(item.Name, item.Length) self.set_mb_graph_interval() - self.get_cm_length_list() + #self.get_cm_length_list() def set_mb_graph_interval(self): |