about summary refs log tree commit diff
diff options
context:
space:
mode:
-rwxr-xr-xwqflask/base/data_set.py8
-rwxr-xr-xwqflask/wqflask/do_search.py28
-rwxr-xr-xwqflask/wqflask/templates/search_result_page.html6
3 files changed, 7 insertions, 35 deletions
diff --git a/wqflask/base/data_set.py b/wqflask/base/data_set.py
index 706b193d..acfee3d4 100755
--- a/wqflask/base/data_set.py
+++ b/wqflask/base/data_set.py
@@ -789,7 +789,7 @@ class PhenotypeDataSet(DataSet):
 
                         this_trait.LRS_score_repr = LRS_score_repr = '%3.1f' % this_trait.lrs
                         this_trait.LRS_score_value = LRS_score_value = this_trait.lrs
-                        this_trait.LRS_location_repr = LRS_location_repr = 'Chr %s: %.4f Mb' % (LRS_Chr, float(LRS_Mb))
+                        this_trait.LRS_location_repr = LRS_location_repr = 'Chr %s: %.6f Mb' % (LRS_Chr, float(LRS_Mb))
                         
     def retrieve_sample_data(self, trait):
         query = """
@@ -880,7 +880,7 @@ class GenotypeDataSet(DataSet):
                     else:
                         trait_location_value = ord(str(this_trait.chr).upper()[0])*1000 + this_trait.mb
 
-                this_trait.location_repr = 'Chr%s: %.4f' % (this_trait.chr, float(this_trait.mb) )
+                this_trait.location_repr = 'Chr%s: %.6f' % (this_trait.chr, float(this_trait.mb) )
                 this_trait.location_value = trait_location_value
                 
     def retrieve_sample_data(self, trait):
@@ -1107,7 +1107,7 @@ class MrnaAssayDataSet(DataSet):
                 #                               this_trait.mb)
 
                 #ZS: Put this in function currently called "convert_location_to_value"
-                this_trait.location_repr = 'Chr %s: %.4f Mb' % (this_trait.chr,
+                this_trait.location_repr = 'Chr %s: %.6f Mb' % (this_trait.chr,
                                                                 float(this_trait.mb))
                 this_trait.location_value = trait_location_value
 
@@ -1163,7 +1163,7 @@ class MrnaAssayDataSet(DataSet):
 
                     this_trait.LRS_score_repr = '%3.1f' % this_trait.lrs
                     this_trait.LRS_score_value = this_trait.lrs
-                    this_trait.LRS_location_repr = 'Chr %s: %.4f Mb' % (lrs_chr, float(lrs_mb))
+                    this_trait.LRS_location_repr = 'Chr %s: %.6f' % (lrs_chr, float(lrs_mb))
       
 
     def convert_location_to_value(self, chromosome, mb):
diff --git a/wqflask/wqflask/do_search.py b/wqflask/wqflask/do_search.py
index 5b042940..f966b564 100755
--- a/wqflask/wqflask/do_search.py
+++ b/wqflask/wqflask/do_search.py
@@ -442,13 +442,6 @@ class WikiSearch(MrnaAssaySearch):
         return where_clause
 
     def run(self):
-        #where_clause = """%s.symbol = GeneRIF.symbol
-        #    and GeneRIF.versionId=0 and GeneRIF.display>0
-        #    and (GeneRIF.comment REGEXP '%s' or GeneRIF.initial = '%s')
-        #        """ % (self.dataset.type,
-        #               "[[:<:]]"+str(self.search_term[0])+"[[:>:]]",
-        #               str(self.search_term[0]))
-
         where_clause = self.get_where_clause()
 
         from_clause = ", GeneRIF "
@@ -747,27 +740,6 @@ class RangeSearch(MrnaAssaySearch):
         return where_clause
 
     def run(self):
-
-        #self.search_term = [float(value) for value in self.search_term]
-        # 
-        #if self.search_operator == "=":
-        #    assert isinstance(self.search_term, (list, tuple))
-        #    self.range_min, self.range_max = self.search_term[:2]
-        #    self.where_clause = """ (SELECT Pow(2, max(value) -min(value))
-        #                             FROM ProbeSetData
-        #                             WHERE ProbeSetData.Id = ProbeSetXRef.dataId) > %s AND
-        #                            (SELECT Pow(2, max(value) -min(value))
-        #                             FROM ProbeSetData
-        #                             WHERE ProbeSetData.Id = ProbeSetXRef.dataId) < %s
-        #                            """ % self.mescape(min(self.range_min, self.range_max),
-        #                                               max(self.range_min, self.range_max))
-        #else:
-        #    # Deal with >, <, >=, and <=
-        #    self.where_clause = """ (SELECT Pow(2, max(value) -min(value))
-        #                             FROM ProbeSetData
-        #                             WHERE ProbeSetData.Id = ProbeSetXRef.dataId) > %s
-        #                            """ % (escape(self.search_term[0]))
-        
         self.where_clause = self.get_where_clause()
 
         self.query = self.compile_final_query(where_clause = self.where_clause)
diff --git a/wqflask/wqflask/templates/search_result_page.html b/wqflask/wqflask/templates/search_result_page.html
index ebae41af..227dec0b 100755
--- a/wqflask/wqflask/templates/search_result_page.html
+++ b/wqflask/wqflask/templates/search_result_page.html
@@ -82,7 +82,7 @@
                             <TD>{{ this_trait.mean }}</TD>
                             <TD align="right">{{ this_trait.LRS_score_repr }}</TD>
                             <TD>{{ this_trait.LRS_location_repr }}</TD>
-                            <TD>{{ this_trait.additive }}</TD>
+                            <TD>{{ '%0.3f' % this_trait.additive|float }}</TD>
                         {% elif dataset.type == 'Publish' %}
                             <TD>{{ this_trait.description_display }}</TD>
                             <TD>{{ this_trait.authors }}</TD>
@@ -93,7 +93,7 @@
                             </TD>
                             <TD>{{ this_trait.LRS_score_repr }}</TD>
                             <TD>{{ this_trait.LRS_location_repr }}</TD>
-                            <TD>{{ this_trait.additive }}</TD>
+                            <TD>{{ '%0.3f' % this_trait.additive|float }}</TD>
                         {% elif dataset.type == 'Geno' %}
                             <TD>{{ this_trait.location_repr }}</TD>
                         {% endif %}
@@ -183,7 +183,7 @@
                     { "sType": "natural",
                       "sWidth": "12%"  },
                     { "sType": "natural",
-                      "sWidth": "15%"  },
+                      "sWidth": "20%"  },
                     { "sType": "natural" }
                 ],
                 "sDom": "tir",