aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/other_config/dot.pylintrc249
-rw-r--r--wqflask/other_config/nginx-old.conf108
-rw-r--r--wqflask/other_config/nginx_conf/gn2-lei.conf41
-rw-r--r--wqflask/other_config/nginx_conf/gn2-zach.conf52
-rw-r--r--wqflask/other_config/nginx_conf/gn2.conf41
-rw-r--r--wqflask/other_config/nginx_conf/gn2_sam.conf42
-rw-r--r--wqflask/other_config/nginx_conf/penguin.conf44
-rw-r--r--wqflask/other_config/pylintrc264
-rw-r--r--wqflask/wqflask/correlation/show_corr_results.py43
-rw-r--r--wqflask/wqflask/do_search.py1
-rw-r--r--wqflask/wqflask/static/dbdoc/TODO.md1
-rw-r--r--wqflask/wqflask/static/new/javascript/show_trait.js176
-rw-r--r--wqflask/wqflask/templates/base.html3
-rw-r--r--wqflask/wqflask/templates/marker_regression_gn1.html9
-rw-r--r--wqflask/wqflask/user_manager.py18
15 files changed, 159 insertions, 933 deletions
diff --git a/wqflask/other_config/dot.pylintrc b/wqflask/other_config/dot.pylintrc
deleted file mode 100644
index 2774300a..00000000
--- a/wqflask/other_config/dot.pylintrc
+++ /dev/null
@@ -1,249 +0,0 @@
-[MASTER]
-
-# Specify a configuration file.
-#rcfile=
-
-# Python code to execute, usually for sys.path manipulation such as
-# pygtk.require().
-#init-hook=
-
-# Profiled execution.
-profile=no
-
-# Add files or directories to the blacklist. They should be base names, not
-# paths.
-ignore=CVS
-
-# Pickle collected data for later comparisons.
-persistent=yes
-
-# List of plugins (as comma separated values of python modules names) to load,
-# usually to register additional checkers.
-load-plugins=
-
-
-[MESSAGES CONTROL]
-
-# Enable the message, report, category or checker with the given id(s). You can
-# either give multiple identifier separated by comma (,) or put this option
-# multiple time.
-#enable=
-
-# Disable the message, report, category or checker with the given id(s). You
-# can either give multiple identifier separated by comma (,) or put this option
-# multiple time (only on the command line, not in the configuration file where
-# it should appear only once).
-#disable=
-
-
-[REPORTS]
-
-# Set the output format. Available formats are text, parseable, colorized, msvs
-# (visual studio) and html
-output-format=colorized
-
-# Include message's id in output
-include-ids=no
-
-# Put messages in a separate file for each module / package specified on the
-# command line instead of printing them on stdout. Reports (if any) will be
-# written in a file name "pylint_global.[txt|html]".
-files-output=no
-
-# Tells whether to display a full report or only the messages
-reports=yes
-
-# Python expression which should return a note less than 10 (10 is the highest
-# note). You have access to the variables errors warning, statement which
-# respectively contain the number of errors / warnings messages and the total
-# number of statements analyzed. This is used by the global evaluation report
-# (RP0004).
-evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10)
-
-# Add a comment according to your evaluation note. This is used by the global
-# evaluation report (RP0004).
-comment=no
-
-
-[MISCELLANEOUS]
-
-# List of note tags to take in consideration, separated by a comma.
-notes=FIXME,XXX,TODO
-
-
-[TYPECHECK]
-
-# Tells whether missing members accessed in mixin class should be ignored. A
-# mixin class is detected if its name ends with "mixin" (case insensitive).
-ignore-mixin-members=yes
-
-# List of classes names for which member attributes should not be checked
-# (useful for classes with attributes dynamically set).
-ignored-classes=SQLObject
-
-# When zope mode is activated, add a predefined set of Zope acquired attributes
-# to generated-members.
-zope=no
-
-# List of members which are set dynamically and missed by pylint inference
-# system, and so shouldn't trigger E0201 when accessed. Python regular
-# expressions are accepted.
-generated-members=REQUEST,acl_users,aq_parent
-
-
-[SIMILARITIES]
-
-# Minimum lines number of a similarity.
-min-similarity-lines=4
-
-# Ignore comments when computing similarities.
-ignore-comments=yes
-
-# Ignore docstrings when computing similarities.
-ignore-docstrings=yes
-
-
-[BASIC]
-
-# Required attributes for module, separated by a comma
-required-attributes=
-
-# List of builtins function names that should not be used, separated by a comma
-bad-functions=map,filter,apply,input
-
-# Regular expression which should only match correct module names
-module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
-
-# Regular expression which should only match correct module level names
-const-rgx=(([A-Z_][A-Z0-9_]*)|(__.*__))$
-
-# Regular expression which should only match correct class names
-class-rgx=[A-Z_][a-zA-Z0-9]+$
-
-# Regular expression which should only match correct function names
-function-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct method names
-method-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct instance attribute names
-attr-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct argument names
-argument-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct variable names
-variable-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct list comprehension /
-# generator expression variable names
-inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$
-
-# Good variable names which should always be accepted, separated by a comma
-good-names=i,j,k,ex,Run,_
-
-# Bad variable names which should always be refused, separated by a comma
-bad-names=foo,bar,baz,toto,tutu,tata
-
-# Regular expression which should only match functions or classes name which do
-# not require a docstring
-no-docstring-rgx=__.*__
-
-
-[VARIABLES]
-
-# Tells whether we should check for unused import in __init__ files.
-init-import=no
-
-# A regular expression matching the beginning of the name of dummy variables
-# (i.e. not used).
-dummy-variables-rgx=_|dummy
-
-# List of additional names supposed to be defined in builtins. Remember that
-# you should avoid to define new builtins when possible.
-additional-builtins=
-
-
-[FORMAT]
-
-# Maximum number of characters on a single line.
-max-line-length=100
-
-# Maximum number of lines in a module
-max-module-lines=1000
-
-# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
-# tab).
-indent-string=' '
-
-
-[IMPORTS]
-
-# Deprecated modules which should not be used, separated by a comma
-deprecated-modules=regsub,string,TERMIOS,Bastion,rexec
-
-# Create a graph of every (i.e. internal and external) dependencies in the
-# given file (report RP0402 must not be disabled)
-import-graph=
-
-# Create a graph of external dependencies in the given file (report RP0402 must
-# not be disabled)
-ext-import-graph=
-
-# Create a graph of internal dependencies in the given file (report RP0402 must
-# not be disabled)
-int-import-graph=
-
-
-[DESIGN]
-
-# Maximum number of arguments for function / method
-max-args=5
-
-# Argument names that match this expression will be ignored. Default to name
-# with leading underscore
-ignored-argument-names=_.*
-
-# Maximum number of locals for function / method body
-max-locals=15
-
-# Maximum number of return / yield for function / method body
-max-returns=6
-
-# Maximum number of branch for function / method body
-max-branchs=12
-
-# Maximum number of statements in function / method body
-max-statements=50
-
-# Maximum number of parents for a class (see R0901).
-max-parents=7
-
-# Maximum number of attributes for a class (see R0902).
-max-attributes=7
-
-# Minimum number of public methods for a class (see R0903).
-min-public-methods=2
-
-# Maximum number of public methods for a class (see R0904).
-max-public-methods=20
-
-
-[CLASSES]
-
-# List of interface methods to ignore, separated by a comma. This is used for
-# instance to not check methods defines in Zope's Interface base class.
-ignore-iface-methods=isImplementedBy,deferred,extends,names,namesAndDescriptions,queryDescriptionFor,getBases,getDescriptionFor,getDoc,getName,getTaggedValue,getTaggedValueTags,isEqualOrExtendedBy,setTaggedValue,isImplementedByInstancesOf,adaptWith,is_implemented_by
-
-# List of method names used to declare (i.e. assign) instance attributes.
-defining-attr-methods=__init__,__new__,setUp
-
-# List of valid names for the first argument in a class method.
-valid-classmethod-first-arg=cls
-
-
-[EXCEPTIONS]
-
-# Exceptions that will emit a warning when being caught. Defaults to
-# "Exception"
-overgeneral-exceptions=Exception
diff --git a/wqflask/other_config/nginx-old.conf b/wqflask/other_config/nginx-old.conf
deleted file mode 100644
index 65ee768c..00000000
--- a/wqflask/other_config/nginx-old.conf
+++ /dev/null
@@ -1,108 +0,0 @@
-
-#user nobody;
-worker_processes 1;
-
-#error_log logs/error.log;
-#error_log logs/error.log notice;
-#error_log logs/error.log info;
-
-#pid logs/nginx.pid;
-
-
-events {
- worker_connections 1024;
-}
-
-
-http {
- include mime.types;
- default_type application/octet-stream;
-
- #log_format main '$remote_addr - $remote_user [$time_local] "$request" '
- # '$status $body_bytes_sent "$http_referer" '
- # '"$http_user_agent" "$http_x_forwarded_for"';
-
- #access_log logs/access.log main;
-
- sendfile on;
- #tcp_nopush on;
-
- #keepalive_timeout 0;
- keepalive_timeout 65;
-
- gzip on;
-
- server {
- # Modeled after http://flask.pocoo.org/docs/deploying/wsgi-standalone/
- listen 80;
-
- server_name _;
-
- access_log /var/log/nginx/access.log;
- error_log /var/log/nginx/error.log;
-
- location ^~ /css/ {
- root /home/sam/gene/wqflask/wqflask/static/;
- }
-
- location ^~ /javascript/ {
- root /home/sam/gene/wqflask/wqflask/static/;
- }
-
-# location ^~ /image/ {
-# root /home/sam/gene/wqflask/wqflask/static/;
-# }
-
- location ^~ /images/ {
- root /home/sam/gene/wqflask/wqflask/static/;
- }
-
- location / {
- proxy_pass http://127.0.0.1:5000/;
- 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;
- }
-
- }
-
-
- # another virtual host using mix of IP-, name-, and port-based configuration
- #
- #server {
- # listen 8000;
- # listen somename:8080;
- # server_name somename alias another.alias;
-
- # location / {
- # root html;
- # index index.html index.htm;
- # }
- #}
-
-
- # HTTPS server
- #
- #server {
- # listen 443;
- # server_name localhost;
-
- # ssl on;
- # ssl_certificate cert.pem;
- # ssl_certificate_key cert.key;
-
- # ssl_session_timeout 5m;
-
- # ssl_protocols SSLv2 SSLv3 TLSv1;
- # ssl_ciphers HIGH:!aNULL:!MD5;
- # ssl_prefer_server_ciphers on;
-
- # location / {
- # root html;
- # index index.html index.htm;
- # }
- #}
-
-}
diff --git a/wqflask/other_config/nginx_conf/gn2-lei.conf b/wqflask/other_config/nginx_conf/gn2-lei.conf
deleted file mode 100644
index 893ad435..00000000
--- a/wqflask/other_config/nginx_conf/gn2-lei.conf
+++ /dev/null
@@ -1,41 +0,0 @@
-server {
- # Modeled after http://flask.pocoo.org/docs/deploying/wsgi-standalone/
- listen 80;
-
- server_name gn2-lei.genenetwork.org;
-
- access_log /var/log/nginx/lei_access.log;
- error_log /var/log/nginx/lei_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 / {
- proxy_pass http://127.0.0.1:5001/;
- 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 100644
index 38347292..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/other_config/nginx_conf/gn2.conf b/wqflask/other_config/nginx_conf/gn2.conf
deleted file mode 100644
index a51b4113..00000000
--- a/wqflask/other_config/nginx_conf/gn2.conf
+++ /dev/null
@@ -1,41 +0,0 @@
-server {
- # Modeled after http://flask.pocoo.org/docs/deploying/wsgi-standalone/
- listen 80;
-
- server_name gn2.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 / {
- proxy_pass http://127.0.0.1:5000/;
- 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_sam.conf b/wqflask/other_config/nginx_conf/gn2_sam.conf
deleted file mode 100644
index f9abbbd2..00000000
--- a/wqflask/other_config/nginx_conf/gn2_sam.conf
+++ /dev/null
@@ -1,42 +0,0 @@
-server {
- # Modeled after http://flask.pocoo.org/docs/deploying/wsgi-standalone/
- listen 80;
-
- server_name gn2_sam.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 / {
- proxy_pass http://127.0.0.1:5005/;
- 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/penguin.conf b/wqflask/other_config/nginx_conf/penguin.conf
deleted file mode 100644
index c819951c..00000000
--- a/wqflask/other_config/nginx_conf/penguin.conf
+++ /dev/null
@@ -1,44 +0,0 @@
-server {
- # Modeled after http://flask.pocoo.org/docs/deploying/wsgi-standalone/
-
- client_max_body_size 20M;
- listen 80;
-
- server_name penguin.uthsc.edu;
-
- 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 / {
- proxy_pass http://127.0.0.1:5000/;
- 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/pylintrc b/wqflask/other_config/pylintrc
deleted file mode 100644
index b23af7a4..00000000
--- a/wqflask/other_config/pylintrc
+++ /dev/null
@@ -1,264 +0,0 @@
-[MASTER]
-
-# Specify a configuration file.
-#rcfile=
-
-# Python code to execute, usually for sys.path manipulation such as
-# pygtk.require().
-#init-hook=
-
-# Profiled execution.
-profile=no
-
-# Add files or directories to the blacklist. They should be base names, not
-# paths.
-ignore=CVS
-
-# Pickle collected data for later comparisons.
-persistent=yes
-
-# List of plugins (as comma separated values of python modules names) to load,
-# usually to register additional checkers.
-load-plugins=
-
-
-[MESSAGES CONTROL]
-
-# Enable the message, report, category or checker with the given id(s). You can
-# either give multiple identifier separated by comma (,) or put this option
-# multiple time. See also the "--disable" option for examples.
-#enable=
-
-# Disable the message, report, category or checker with the given id(s). You
-# can either give multiple identifiers separated by comma (,) or put this
-# option multiple times (only on the command line, not in the configuration
-# file where it should appear only once).You can also use "--disable=all" to
-# disable everything first and then reenable specific checks. For example, if
-# you want to run only the similarities checker, you can use "--disable=all
-# --enable=similarities". If you want to run only the classes checker, but have
-# no Warning level messages displayed, use"--disable=all --enable=classes
-# --disable=W"
-disable=no-init, star-args, no-member, import-error
-
-
-[REPORTS]
-
-# Set the output format. Available formats are text, parseable, colorized, msvs
-# (visual studio) and html. You can also give a reporter class, eg
-# mypackage.mymodule.MyReporterClass.
-output-format=text
-
-# Include message's id in output
-include-ids=no
-
-# Include symbolic ids of messages in output
-symbols=no
-
-# Put messages in a separate file for each module / package specified on the
-# command line instead of printing them on stdout. Reports (if any) will be
-# written in a file name "pylint_global.[txt|html]".
-files-output=no
-
-# Tells whether to display a full report or only the messages
-reports=yes
-
-# Python expression which should return a note less than 10 (10 is the highest
-# note). You have access to the variables errors warning, statement which
-# respectively contain the number of errors / warnings messages and the total
-# number of statements analyzed. This is used by the global evaluation report
-# (RP0004).
-evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10)
-
-# Add a comment according to your evaluation note. This is used by the global
-# evaluation report (RP0004).
-comment=no
-
-
-[SIMILARITIES]
-
-# Minimum lines number of a similarity.
-min-similarity-lines=4
-
-# Ignore comments when computing similarities.
-ignore-comments=yes
-
-# Ignore docstrings when computing similarities.
-ignore-docstrings=yes
-
-# Ignore imports when computing similarities.
-ignore-imports=no
-
-
-[VARIABLES]
-
-# Tells whether we should check for unused import in __init__ files.
-init-import=no
-
-# A regular expression matching the beginning of the name of dummy variables
-# (i.e. not used).
-dummy-variables-rgx=_|dummy
-
-# List of additional names supposed to be defined in builtins. Remember that
-# you should avoid to define new builtins when possible.
-additional-builtins=
-
-
-[BASIC]
-
-# Required attributes for module, separated by a comma
-required-attributes=
-
-# List of builtins function names that should not be used, separated by a comma
-bad-functions=map,filter,apply,input
-
-# Regular expression which should only match correct module names
-module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
-
-# Regular expression which should only match correct module level names
-const-rgx=(([A-Z_][A-Za-z0-9_]*)|(__.*__))$
-
-# Regular expression which should only match correct class names
-class-rgx=[A-Z_][a-zA-Z0-9]+$
-
-# Regular expression which should only match correct function names
-function-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct method names
-method-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct instance attribute names
-attr-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct argument names
-argument-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct variable names
-variable-rgx=[a-z_][a-z0-9_]{2,30}$
-
-# Regular expression which should only match correct list comprehension /
-# generator expression variable names
-inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$
-
-# Good variable names which should always be accepted, separated by a comma
-good-names=i,j,k,ex,Run,_
-
-# Bad variable names which should always be refused, separated by a comma
-bad-names=foo,bar,baz,toto,tutu,tata
-
-# Regular expression which should only match functions or classes name which do
-# not require a docstring
-no-docstring-rgx=__.*__
-
-
-[FORMAT]
-
-# Maximum number of characters on a single line.
-max-line-length=100
-
-# Maximum number of lines in a module
-max-module-lines=1000
-
-# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
-# tab).
-indent-string=' '
-
-
-[MISCELLANEOUS]
-
-# List of note tags to take in consideration, separated by a comma.
-notes=FIXME,XXX,TODO
-
-
-[TYPECHECK]
-
-# Tells whether missing members accessed in mixin class should be ignored. A
-# mixin class is detected if its name ends with "mixin" (case insensitive).
-ignore-mixin-members=yes
-
-# List of classes names for which member attributes should not be checked
-# (useful for classes with attributes dynamically set).
-ignored-classes=SQLObject
-
-# When zope mode is activated, add a predefined set of Zope acquired attributes
-# to generated-members.
-zope=no
-
-# List of members which are set dynamically and missed by pylint inference
-# system, and so shouldn't trigger E0201 when accessed. Python regular
-# expressions are accepted.
-generated-members=REQUEST,acl_users,aq_parent
-
-
-[DESIGN]
-
-# Maximum number of arguments for function / method
-max-args=5
-
-# Argument names that match this expression will be ignored. Default to name
-# with leading underscore
-ignored-argument-names=_.*
-
-# Maximum number of locals for function / method body
-max-locals=15
-
-# Maximum number of return / yield for function / method body
-max-returns=6
-
-# Maximum number of branch for function / method body
-max-branchs=12
-
-# Maximum number of statements in function / method body
-max-statements=50
-
-# Maximum number of parents for a class (see R0901).
-max-parents=7
-
-# Maximum number of attributes for a class (see R0902).
-max-attributes=7
-
-# Minimum number of public methods for a class (see R0903).
-min-public-methods=2
-
-# Maximum number of public methods for a class (see R0904).
-max-public-methods=20
-
-
-[IMPORTS]
-
-# Deprecated modules which should not be used, separated by a comma
-deprecated-modules=regsub,string,TERMIOS,Bastion,rexec
-
-# Create a graph of every (i.e. internal and external) dependencies in the
-# given file (report RP0402 must not be disabled)
-import-graph=
-
-# Create a graph of external dependencies in the given file (report RP0402 must
-# not be disabled)
-ext-import-graph=
-
-# Create a graph of internal dependencies in the given file (report RP0402 must
-# not be disabled)
-int-import-graph=
-
-
-[CLASSES]
-
-# List of interface methods to ignore, separated by a comma. This is used for
-# instance to not check methods defines in Zope's Interface base class.
-ignore-iface-methods=isImplementedBy,deferred,extends,names,namesAndDescriptions,queryDescriptionFor,getBases,getDescriptionFor,getDoc,getName,getTaggedValue,getTaggedValueTags,isEqualOrExtendedBy,setTaggedValue,isImplementedByInstancesOf,adaptWith,is_implemented_by
-
-# List of method names used to declare (i.e. assign) instance attributes.
-defining-attr-methods=__init__,__new__,setUp
-
-# List of valid names for the first argument in a class method.
-valid-classmethod-first-arg=cls
-
-# List of valid names for the first argument in a metaclass class method.
-valid-metaclass-classmethod-first-arg=mcs
-
-
-[EXCEPTIONS]
-
-# Exceptions that will emit a warning when being caught. Defaults to
-# "Exception"
-overgeneral-exceptions=Exception
diff --git a/wqflask/wqflask/correlation/show_corr_results.py b/wqflask/wqflask/correlation/show_corr_results.py
index 2c6c3a14..73072423 100644
--- a/wqflask/wqflask/correlation/show_corr_results.py
+++ b/wqflask/wqflask/correlation/show_corr_results.py
@@ -196,28 +196,29 @@ class CorrelationResults(object):
self.get_sample_r_and_p_values(trait, self.target_dataset.trait_data[trait])
elif self.corr_type == "sample":
- if self.dataset.type == "ProbeSet" and cache_available:
- dataset_file = open(webqtlConfig.GENERATED_TEXT_DIR+db_filename,'r')
-
- #XZ, 01/08/2009: read the first line
- line = dataset_file.readline()
- dataset_strains = webqtlUtil.readLineCSV(line)[1:]
-
- self.this_trait_vals = []
- for item in dataset_strains:
- if item in self.sample_data:
- self.this_trait_vals.append(self.sample_data[item])
- else:
- self.this_trait_vals.append("None")
- num_overlap = len(self.this_trait_vals)
- logger.debug("DOING PARALLEL")
- self.do_parallel_correlation(db_filename, num_overlap)
- else:
- for trait, values in self.target_dataset.trait_data.iteritems():
- self.get_sample_r_and_p_values(trait, values)
+ #ZS: Commented out since parallel correlation has issues with gunicorn
+ # if self.dataset.type == "ProbeSet" and cache_available:
+ # dataset_file = open(webqtlConfig.GENERATED_TEXT_DIR+db_filename,'r')
+
+ ##XZ, 01/08/2009: read the first line
+ # line = dataset_file.readline()
+ # dataset_strains = webqtlUtil.readLineCSV(line)[1:]
+
+ # self.this_trait_vals = []
+ # for item in dataset_strains:
+ # if item in self.sample_data:
+ # self.this_trait_vals.append(self.sample_data[item])
+ # else:
+ # self.this_trait_vals.append("None")
+ # num_overlap = len(self.this_trait_vals)
+ # logger.debug("DOING PARALLEL")
+ # self.do_parallel_correlation(db_filename, num_overlap)
+ # else:
+ for trait, values in self.target_dataset.trait_data.iteritems():
+ self.get_sample_r_and_p_values(trait, values)
- self.correlation_data = collections.OrderedDict(sorted(self.correlation_data.items(),
- key=lambda t: -abs(t[1][0])))
+ self.correlation_data = collections.OrderedDict(sorted(self.correlation_data.items(),
+ key=lambda t: -abs(t[1][0])))
if self.target_dataset.type == "ProbeSet" or self.target_dataset.type == "Geno":
diff --git a/wqflask/wqflask/do_search.py b/wqflask/wqflask/do_search.py
index e1df1e63..17625474 100644
--- a/wqflask/wqflask/do_search.py
+++ b/wqflask/wqflask/do_search.py
@@ -989,3 +989,4 @@ if __name__ == "__main__":
#results = GoSearch("0045202", dataset, cursor, db_conn).run()
logger.debug("results are:", pf(results))
+ db_conn.close()
diff --git a/wqflask/wqflask/static/dbdoc/TODO.md b/wqflask/wqflask/static/dbdoc/TODO.md
deleted file mode 100644
index c0a8bab7..00000000
--- a/wqflask/wqflask/static/dbdoc/TODO.md
+++ /dev/null
@@ -1 +0,0 @@
-TODO: Add all database documentation into this folder
diff --git a/wqflask/wqflask/static/new/javascript/show_trait.js b/wqflask/wqflask/static/new/javascript/show_trait.js
index df10c060..117d8f12 100644
--- a/wqflask/wqflask/static/new/javascript/show_trait.js
+++ b/wqflask/wqflask/static/new/javascript/show_trait.js
@@ -250,15 +250,29 @@
};
redraw_box_plot = function() {
- var x;
- var _i, _len, _ref, data;
- _ref = _.values(root.selected_samples[root.stats_group]);
- trait_vals = [];
- for (_i = 0, _len = _ref.length; _i < _len; _i++) {
- x = _ref[_i];
- trait_vals.push(x.value);
+ var y_value_list = []
+ for (var sample_group in root.selected_samples){
+ var trait_sample_data = _.values(root.selected_samples[sample_group])
+ var trait_vals = [];
+ for (i = 0, len = trait_sample_data.length; i < len; i++) {
+ this_sample_data = trait_sample_data[i];
+ trait_vals.push(this_sample_data.value);
+ }
+ y_value_list.push(trait_vals)
+ }
+
+ if (Object.keys(js_data.sample_group_types).length > 1) {
+ var update = {
+ y: y_value_list
+ }
+ console.log("REDRAW UPDATE:", update)
+ Plotly.restyle('box_plot', update, [0, 1, 2])
+ } else {
+ var update = {
+ y: y_value_list
+ }
+ Plotly.restyle('box_plot', update)
}
- Plotly.restyle('box_plot', 'y', [trait_vals])
}
redraw_prob_plot = function() {
@@ -640,6 +654,108 @@
};
root.stats_group = 'samples_primary';
+
+ if (Object.keys(js_data.sample_group_types).length > 1) {
+ full_sample_lists = [sample_lists[0], sample_lists[1], sample_lists[0].concat(sample_lists[1])]
+ sample_group_list = [js_data.sample_group_types['samples_primary'], js_data.sample_group_types['samples_other'], js_data.sample_group_types['samples_all']]
+ } else {
+ full_sample_lists = [sample_lists[0]]
+ sample_group_list = [js_data.sample_group_types['samples_primary']]
+ }
+
+ if (full_sample_lists.length > 1) {
+ var box_layout = {
+ width: 1200,
+ height: 500,
+ margin: {
+ l: 50,
+ r: 30,
+ t: 30,
+ b: 80
+ }
+ };
+ var trace1 = {
+ y: get_sample_vals(full_sample_lists[0]),
+ type: 'box',
+ name: sample_group_list[0],
+ boxpoints: 'all',
+ jitter: 0.5,
+ whiskerwidth: 0.2,
+ fillcolor: 'cls',
+ marker: {
+ size: 2
+ },
+ line: {
+ width: 1
+ }
+ }
+ var trace2 = {
+ y: get_sample_vals(full_sample_lists[1]),
+ type: 'box',
+ name: sample_group_list[1],
+ boxpoints: 'all',
+ jitter: 0.5,
+ whiskerwidth: 0.2,
+ fillcolor: 'cls',
+ marker: {
+ size: 2
+ },
+ line: {
+ width: 1
+ }
+ }
+ var trace3 = {
+ y: get_sample_vals(full_sample_lists[2]),
+ type: 'box',
+ name: sample_group_list[2],
+ boxpoints: 'all',
+ jitter: 0.5,
+ whiskerwidth: 0.2,
+ fillcolor: 'cls',
+ marker: {
+ size: 2
+ },
+ line: {
+ width: 1
+ }
+ }
+ box_data = [trace1, trace2, trace3]
+ } else {
+ var box_layout = {
+ width: 500,
+ height: 500,
+ margin: {
+ l: 50,
+ r: 30,
+ t: 30,
+ b: 80
+ }
+ };
+ box_data = [
+ {
+ type: 'box',
+ y: get_sample_vals(full_sample_lists[0]),
+ name: sample_group_list[0],
+ boxpoints: 'all',
+ jitter: 0.5,
+ whiskerwidth: 0.2,
+ fillcolor: 'cls',
+ marker: {
+ size: 2
+ },
+ line: {
+ width: 1
+ }
+ }
+ ]
+ }
+
+ obj = {
+ data: box_data,
+ layout: box_layout
+ }
+ Plotly.newPlot('box_plot', obj);
+
// Histogram
var hist_trace = {
x: get_sample_vals(sample_lists[0]),
@@ -686,50 +802,6 @@
root.bar_layout = layout
Plotly.newPlot('bar_chart', root.bar_data, layout)
- if (Object.keys(js_data.sample_group_types).length > 1) {
- full_sample_lists = [sample_lists[0], sample_lists[1], sample_lists[0].concat(sample_lists[1])]
- sample_group_list = [js_data.sample_group_types['samples_primary'], js_data.sample_group_types['samples_other'], js_data.sample_group_types['samples_all']]
- } else {
- full_sample_lists = [sample_lists[0]]
- sample_group_list = [js_data.sample_group_types['samples_primary']]
- }
-
- data = []
- for ( var i = 0; i < full_sample_lists.length; i ++ ) {
- var box_trace = {
- type: 'box',
- y: get_sample_vals(full_sample_lists[i]),
- name: sample_group_list[i],
- boxpoints: 'all',
- jitter: 0.5,
- whiskerwidth: 0.2,
- fillcolor: 'cls',
- marker: {
- size: 2
- },
- line: {
- width: 1
- }
- };
- data.push(box_trace)
- };
- layout = {
- title: 'Box Plot',
- yaxis: {
- autorange: true,
- showgrid: true,
- zeroline: true
- },
- margin: {
- l: 50,
- r: 30,
- t: 80,
- b: 80
- }
- };
-
- Plotly.newPlot('box_plot', data, layout);
-
$('.histogram_samples_group').val(root.stats_group);
$('.histogram_samples_group').change(function() {
root.stats_group = $(this).val();
diff --git a/wqflask/wqflask/templates/base.html b/wqflask/wqflask/templates/base.html
index 237a65f3..41bdaddc 100644
--- a/wqflask/wqflask/templates/base.html
+++ b/wqflask/wqflask/templates/base.html
@@ -77,6 +77,9 @@
{% endif %}
</li>
<li style="margin-left: 20px;">
+ <a href="http://gn2-guix.genenetwork.org" style="font-weight: bold;" >Use Staging Branch</a>
+ </li>
+ <li style="margin-left: 20px;">
<a href="http://www.genenetwork.org" style="font-weight: bold;" >Use GeneNetwork 1</a>
</li>
</ul>
diff --git a/wqflask/wqflask/templates/marker_regression_gn1.html b/wqflask/wqflask/templates/marker_regression_gn1.html
index 08a934a6..fd083983 100644
--- a/wqflask/wqflask/templates/marker_regression_gn1.html
+++ b/wqflask/wqflask/templates/marker_regression_gn1.html
@@ -183,6 +183,13 @@
{% if selectedChr == -1 %}
<div class="container" style="padding-left: 30px; width:{% if 'additive' in trimmed_markers[0] %}45%{% else %}35%{% endif %};">
<h2>Mapping Statistics</h2>
+ <br />
+ <button class="btn btn-default" id="select_all"><span class="glyphicon glyphicon-ok"></span> Select All</button>
+ <button class="btn btn-default" id="deselect_all"><span class="glyphicon glyphicon-remove"></span> Deselect All</button>
+ <button class="btn btn-default" id="invert"><span class="glyphicon glyphicon-resize-vertical"></span> Invert</button>
+ <button class="btn btn-default" id="add" disabled><span class="glyphicon glyphicon-plus-sign"></span> Add</button>
+ <br />
+ <br />
<div id="table_container" style="border-style: solid; border-width: 1px; border-color: black;">
<table id="trait_table" class="table table-hover table-striped nowrap">
<thead>
@@ -211,7 +218,7 @@
<td align="center" style="padding-right: 0px;">
<input type="checkbox" name="selectCheck"
class="checkbox trait_checkbox"
- value="{{ marker.name }}">
+ value="{{ data_hmac('{}:{}Geno'.format(marker.name, dataset.group.name)) }}">
</td>
<td align="right">{{ loop.index }}</td>
<td>{% if geno_db_exists == "True" %}<a href="/show_trait?trait_id={{ marker.name }}&dataset={{ dataset.group.name }}Geno">{{ marker.name }}</a>{% else %}{{ marker.name }}{% endif %}</td>
diff --git a/wqflask/wqflask/user_manager.py b/wqflask/wqflask/user_manager.py
index ebca4807..a0605803 100644
--- a/wqflask/wqflask/user_manager.py
+++ b/wqflask/wqflask/user_manager.py
@@ -23,9 +23,6 @@ import urlparse
import simplejson as json
-import sqlalchemy
-from sqlalchemy import orm
-
#from redis import StrictRedis
import redis
Redis = redis.StrictRedis()
@@ -46,7 +43,6 @@ from wqflask.database import db_session
from wqflask import model
from utility import Bunch, Struct, after
-from utility.tools import LOG_SQL, LOG_SQL_ALCHEMY
import logging
from utility.logger import getLogger
@@ -223,6 +219,7 @@ class UserSession(object):
def user_ob(self):
"""Actual sqlalchemy record"""
# Only look it up once if needed, then store it
+ raise "OBSOLETE: use ElasticSearch instead"
try:
if LOG_SQL_ALCHEMY:
logging.getLogger('sqlalchemy.pool').setLevel(logging.DEBUG)
@@ -844,19 +841,6 @@ def register():
return render_template("new_security/register_user.html", values=params, errors=errors)
-
-
-#@app.route("/n/login", methods=('GET', 'POST'))
-#def login():
-# return user_manager.login()
-#
-#@app.route("/manage/verify")
-#def verify():
-# user_manager.verify_email()
-# return render_template("new_security/verified.html")
-
-
-
################################# Sign and unsign #####################################
def url_for_hmac(endpoint, **values):