about summary refs log tree commit diff
path: root/wqflask/base/trait.py
diff options
context:
space:
mode:
authorzsloan2017-01-26 16:26:16 +0000
committerzsloan2017-01-26 16:26:16 +0000
commite63c4014e7bc34b440707be19af3779b72102fdb (patch)
tree6692f7145db3b620a4e316f4d5289c6809ec9250 /wqflask/base/trait.py
parent2fe052c10bc1e6468da277a6afbb51468e447c47 (diff)
downloadgenenetwork2-e63c4014e7bc34b440707be19af3779b72102fdb.tar.gz
GEMMA now works with CFW data (had to update where it looks for the input files and how it writes the phenotype file)
Y-axis for GEMMA now says -log(p)

Updated the style of the trait sample data table in the trait page

Updated dataset_select_menu_orig.js to also build just the Species and Group drop-downs for the trait input page (as opposed to all 4 drop-downs)

Updated dataset menu json file

Added option to show and hide columns to regular search page using colVis

Changed regular and global search result table styles/column widths

Began work on user trait submission code (not working yet though)

Began work on static loading page for mapping results
Diffstat (limited to 'wqflask/base/trait.py')
-rw-r--r--wqflask/base/trait.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/wqflask/base/trait.py b/wqflask/base/trait.py
index eb5b91c3..bf87e879 100644
--- a/wqflask/base/trait.py
+++ b/wqflask/base/trait.py
@@ -207,7 +207,7 @@ class GeneralTrait(object):
                 formatted = self.post_publication_description
         else:
             formatted = "Not available"
-        return formatted.capitalize()
+        return formatted
 
     @property
     def alias_fmt(self):
@@ -379,7 +379,7 @@ def jsonable_table_row(trait, dataset_name, index):
             additive = "N/A"
         else:
             additive = "%.3f" % round(float(trait.additive), 2)
-        return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" style="transform: scale(1.5);" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
+        return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
                 index,
                 '<a href="/show_trait?trait_id='+str(trait.name)+'&dataset='+dataset.name+'">'+str(trait.name)+'</a>',
                 trait.symbol,
@@ -395,7 +395,7 @@ def jsonable_table_row(trait, dataset_name, index):
         else:
             additive = "%.2f" % round(float(trait.additive), 2)
         if trait.pubmed_id:
-            return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" style="transform: scale(1.5);" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
+            return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
                     index,
                     '<a href="/show_trait?trait_id='+str(trait.name)+'&dataset='+dataset.name+'">'+str(trait.name)+'</a>',
                     trait.description_display,
@@ -405,7 +405,7 @@ def jsonable_table_row(trait, dataset_name, index):
                     trait.LRS_location_repr,
                     additive]
         else:
-            return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" style="transform: scale(1.5);" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
+            return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
                     index,
                     '<a href="/show_trait?trait_id='+str(trait.name)+'&dataset='+dataset.name+'">'+str(trait.name)+'</a>',
                     trait.description_display,
@@ -415,7 +415,7 @@ def jsonable_table_row(trait, dataset_name, index):
                     trait.LRS_location_repr,
                     additive]
     elif dataset.type == "Geno":
-        return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" style="transform: scale(1.5);" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
+        return ['<input type="checkbox" name="searchResult" class="checkbox trait_checkbox" value="' + user_manager.data_hmac('{}:{}'.format(str(trait.name), dataset.name)) + '">',
                 index,
                 '<a href="/show_trait?trait_id='+str(trait.name)+'&dataset='+dataset.name+'">'+str(trait.name)+'</a>',
                 trait.location_repr]
@@ -499,7 +499,7 @@ def retrieve_trait_info(trait, dataset, get_qtl_info=False):
         for i, field in enumerate(dataset.display_fields):
             holder = trait_info[i]
             if isinstance(trait_info[i], basestring):
-                holder = unicode(trait_info[i], "utf8", "ignore")
+                holder = unicode(trait_info[i], "utf-8", "ignore")
             setattr(trait, field, holder)
 
         if dataset.type == 'Publish':