diff options
Diffstat (limited to 'wqflask/base')
-rwxr-xr-x | wqflask/base/data_set.py | 2 | ||||
-rw-r--r-- | wqflask/base/species.py | 10 |
2 files changed, 5 insertions, 7 deletions
diff --git a/wqflask/base/data_set.py b/wqflask/base/data_set.py index 16bc4ba4..111597a9 100755 --- a/wqflask/base/data_set.py +++ b/wqflask/base/data_set.py @@ -83,8 +83,6 @@ class Markers(object): marker['lod_score'] = -math.log10(marker['p_value']) #Using -log(p) for the LRS; need to ask Rob how he wants to get LRS from p-values marker['lrs_value'] = -math.log10(marker['p_value']) * 4.61 - - class HumanMarkers(Markers): diff --git a/wqflask/base/species.py b/wqflask/base/species.py index 689e5c05..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,7 +59,7 @@ 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() |