From fca37195705ac68f21a1f725cf1fe3c59e0d1800 Mon Sep 17 00:00:00 2001 From: zsloan Date: Tue, 26 Jan 2016 19:08:13 +0000 Subject: Removed a bunch of files/directories/packages that are no longer used and some corresponding imports --- wqflask/other_config/nginx_conf/gn2_zach.conf | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'wqflask/other_config') diff --git a/wqflask/other_config/nginx_conf/gn2_zach.conf b/wqflask/other_config/nginx_conf/gn2_zach.conf index 23f3995f..1614bcb4 100755 --- a/wqflask/other_config/nginx_conf/gn2_zach.conf +++ b/wqflask/other_config/nginx_conf/gn2_zach.conf @@ -33,6 +33,11 @@ server { autoindex on; } + location /download/ { + root /home/zas1024/gene/wqflask/wqflask/; + autoindex on; + } + location / { proxy_pass http://127.0.0.1:5002/; proxy_redirect off; -- cgit v1.2.3 From 7f5536635ac20f7c670e4dc8e650f27d47503d78 Mon Sep 17 00:00:00 2001 From: zsloan Date: Mon, 15 Feb 2016 18:00:18 +0000 Subject: Fixed R/qtl mapping so the group (BXD, etc) isn't hardcoded Removed an extraneous tag from the show trait page --- wqflask/other_config/nginx_conf/gn2-zach.conf | 52 ++++++++++++++++++++++ wqflask/other_config/nginx_conf/gn2_zach.conf | 52 ---------------------- .../wqflask/marker_regression/marker_regression.py | 7 ++- wqflask/wqflask/templates/show_trait.html | 4 -- .../wqflask/templates/show_trait_statistics.html | 2 +- 5 files changed, 58 insertions(+), 59 deletions(-) create mode 100755 wqflask/other_config/nginx_conf/gn2-zach.conf delete mode 100755 wqflask/other_config/nginx_conf/gn2_zach.conf (limited to 'wqflask/other_config') diff --git a/wqflask/other_config/nginx_conf/gn2-zach.conf b/wqflask/other_config/nginx_conf/gn2-zach.conf new file mode 100755 index 00000000..38347292 --- /dev/null +++ b/wqflask/other_config/nginx_conf/gn2-zach.conf @@ -0,0 +1,52 @@ +server { + # Modeled after http://flask.pocoo.org/docs/deploying/wsgi-standalone/ + listen 80; + + server_name gn2-zach.genenetwork.org; + + access_log /var/log/nginx/access.log; + error_log /var/log/nginx/error.log; + + location ^~ /css/ { + root /gene/wqflask/wqflask/static/; + } + + location ^~ /javascript/ { + root /gene/wqflask/wqflask/static/; + } + +# location ^~ /image/ { +# root /gene/wqflask/wqflask/static/; +# } + + location ^~ /images/ { + root /gene/wqflask/wqflask/static/; + } + + ### New - added by Sam + #location ^~ /static/ { + # root /gene/wqflask/wqflask/static/; + #} + + location /plink_gemma/ { + root /home/zas1024/gene/wqflask/wqflask/; + autoindex on; + } + + location /download/ { + root /home/zas1024/gene/wqflask/wqflask/; + autoindex on; + } + + location / { + proxy_pass http://127.0.0.1:5002/; + proxy_redirect off; + + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + + proxy_read_timeout 40m; + } +} + diff --git a/wqflask/other_config/nginx_conf/gn2_zach.conf b/wqflask/other_config/nginx_conf/gn2_zach.conf deleted file mode 100755 index 1614bcb4..00000000 --- a/wqflask/other_config/nginx_conf/gn2_zach.conf +++ /dev/null @@ -1,52 +0,0 @@ -server { - # Modeled after http://flask.pocoo.org/docs/deploying/wsgi-standalone/ - listen 80; - - server_name gn2_zach.genenetwork.org; - - access_log /var/log/nginx/access.log; - error_log /var/log/nginx/error.log; - - location ^~ /css/ { - root /gene/wqflask/wqflask/static/; - } - - location ^~ /javascript/ { - root /gene/wqflask/wqflask/static/; - } - -# location ^~ /image/ { -# root /gene/wqflask/wqflask/static/; -# } - - location ^~ /images/ { - root /gene/wqflask/wqflask/static/; - } - - ### New - added by Sam - #location ^~ /static/ { - # root /gene/wqflask/wqflask/static/; - #} - - location /plink_gemma/ { - root /home/zas1024/gene/wqflask/wqflask/; - autoindex on; - } - - location /download/ { - root /home/zas1024/gene/wqflask/wqflask/; - autoindex on; - } - - location / { - proxy_pass http://127.0.0.1:5002/; - proxy_redirect off; - - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - - proxy_read_timeout 40m; - } -} - diff --git a/wqflask/wqflask/marker_regression/marker_regression.py b/wqflask/wqflask/marker_regression/marker_regression.py index d3ee344d..c16c885e 100755 --- a/wqflask/wqflask/marker_regression/marker_regression.py +++ b/wqflask/wqflask/marker_regression/marker_regression.py @@ -298,6 +298,9 @@ class MarkerRegression(object): def geno_to_rqtl_function(self): # TODO: Need to figure out why some genofiles have the wrong format and don't convert properly print("Adding some custom helper functions to the R environment") + + + ro.r(""" trim <- function( x ) { gsub("(^[[:space:]]+|[[:space:]]+$)", "", x) } @@ -306,7 +309,7 @@ class MarkerRegression(object): return(trim(strsplit(header[mat],':')[[1]][2])) } - GENOtoCSVR <- function(genotypes = 'BXD.geno', out = 'cross.csvr', phenotype = NULL, sex = NULL, verbose = FALSE){ + GENOtoCSVR <- function(genotypes = '%s', out = 'cross.csvr', phenotype = NULL, sex = NULL, verbose = FALSE){ header = readLines(genotypes, 40) # Assume a geno header is not longer than 40 lines toskip = which(unlist(lapply(header, function(x){ length(grep("Chr\t", x)) })) == 1)-1 # Major hack to skip the geno headers @@ -325,7 +328,7 @@ class MarkerRegression(object): if(type == 'riset') cross <- convert2riself(cross) # If its a RIL, convert to a RIL in R/qtl return(cross) } - """) + """ % (self.dataset.group.name + ".geno")) def run_rqtl_geno(self): print("Calling R/qtl") diff --git a/wqflask/wqflask/templates/show_trait.html b/wqflask/wqflask/templates/show_trait.html index b4f5b6c2..29239adb 100755 --- a/wqflask/wqflask/templates/show_trait.html +++ b/wqflask/wqflask/templates/show_trait.html @@ -189,8 +189,6 @@ } }); - console.time("Creating table"); - $('#samples_primary, #samples_other').find("tr.outlier").css('background-color', 'yellow') {% if sample_groups[0].se_exists() %} $('#samples_primary, #samples_other').DataTable( { @@ -218,10 +216,8 @@ }, "paging": false } ); - console.timeEnd("Creating table"); {% else %} - console.time("Creating table"); $('#samples_primary, #samples_other').DataTable( { "columns": [ diff --git a/wqflask/wqflask/templates/show_trait_statistics.html b/wqflask/wqflask/templates/show_trait_statistics.html index 34fa2216..2183dd30 100755 --- a/wqflask/wqflask/templates/show_trait_statistics.html +++ b/wqflask/wqflask/templates/show_trait_statistics.html @@ -110,7 +110,7 @@
More about Normal Probability Plots and more - about interpreting these plots from the glossary + about interpreting these plots from the glossary
-- cgit v1.2.3