diff options
-rw-r--r-- | wqflask/wqflask/auwerx/ephewas.py | 40 | ||||
-rw-r--r-- | wqflask/wqflask/auwerx/mediation.py | 40 | ||||
-rw-r--r-- | wqflask/wqflask/auwerx/phewas.py (renamed from wqflask/wqflask/phewas/phewas.py) | 0 | ||||
-rw-r--r-- | wqflask/wqflask/templates/ephewas_analysis.html | 9 | ||||
-rw-r--r-- | wqflask/wqflask/templates/mediation_analysis.html | 9 | ||||
-rw-r--r-- | wqflask/wqflask/templates/phewas_analysis.html | 3 | ||||
-rw-r--r-- | wqflask/wqflask/templates/show_trait_PheWAS_tools.html | 8 |
7 files changed, 104 insertions, 5 deletions
diff --git a/wqflask/wqflask/auwerx/ephewas.py b/wqflask/wqflask/auwerx/ephewas.py new file mode 100644 index 00000000..edfb2801 --- /dev/null +++ b/wqflask/wqflask/auwerx/ephewas.py @@ -0,0 +1,40 @@ +# PheWAS analysis for GN2 +# Author / Maintainer: Li Hao & Danny Arends <Danny.Arends@gmail.com> +import sys +from numpy import * +import scipy as sp # SciPy +import rpy2.robjects as ro # R Objects +import rpy2.rinterface as ri + +from base.webqtlConfig import GENERATED_IMAGE_DIR +from utility import webqtlUtil # Random number for the image +from utility import genofile_parser # genofile_parser + +import base64 +import array +import csv +import itertools + +from base import data_set +from base import trait as TRAIT + +from utility import helper_functions +from utility.tools import locate + +from rpy2.robjects.packages import importr +utils = importr("utils") + +class EPheWAS(object): + def __init__(self): + print("Initialization of ePheWAS") + print("Initialization of ePheWAS done !") + + def run_analysis(self, requestform): + print("Starting ePheWAS analysis on dataset") + print("Initialization of ePheWAS done !") + + def process_results(self, results): + print("Processing ePheWAS output") + template_vars = {} + return(dict(template_vars)) + diff --git a/wqflask/wqflask/auwerx/mediation.py b/wqflask/wqflask/auwerx/mediation.py new file mode 100644 index 00000000..48d02dc2 --- /dev/null +++ b/wqflask/wqflask/auwerx/mediation.py @@ -0,0 +1,40 @@ +# PheWAS analysis for GN2 +# Author / Maintainer: Li Hao & Danny Arends <Danny.Arends@gmail.com> +import sys +from numpy import * +import scipy as sp # SciPy +import rpy2.robjects as ro # R Objects +import rpy2.rinterface as ri + +from base.webqtlConfig import GENERATED_IMAGE_DIR +from utility import webqtlUtil # Random number for the image +from utility import genofile_parser # genofile_parser + +import base64 +import array +import csv +import itertools + +from base import data_set +from base import trait as TRAIT + +from utility import helper_functions +from utility.tools import locate + +from rpy2.robjects.packages import importr +utils = importr("utils") + +class Mediation(object): + def __init__(self): + print("Initialization of Mediation") + print("Initialization of Mediation done !") + + def run_analysis(self, requestform): + print("Starting Mediation analysis on dataset") + print("Initialization of Mediation done !") + + def process_results(self, results): + print("Processing Mediation output") + template_vars = {} + return(dict(template_vars)) + diff --git a/wqflask/wqflask/phewas/phewas.py b/wqflask/wqflask/auwerx/phewas.py index 399e056c..399e056c 100644 --- a/wqflask/wqflask/phewas/phewas.py +++ b/wqflask/wqflask/auwerx/phewas.py diff --git a/wqflask/wqflask/templates/ephewas_analysis.html b/wqflask/wqflask/templates/ephewas_analysis.html new file mode 100644 index 00000000..d5e71fa7 --- /dev/null +++ b/wqflask/wqflask/templates/ephewas_analysis.html @@ -0,0 +1,9 @@ +{% extends "base.html" %} +{% block title %}ePheWAS analysis{% endblock %} + +{% block content %} <!-- Start of body --> +<div class="container"> + <h1>ePheWAS analysis results</h1> + YAY ! We have our own route +</div> +{% endblock %} diff --git a/wqflask/wqflask/templates/mediation_analysis.html b/wqflask/wqflask/templates/mediation_analysis.html new file mode 100644 index 00000000..ee5a5016 --- /dev/null +++ b/wqflask/wqflask/templates/mediation_analysis.html @@ -0,0 +1,9 @@ +{% extends "base.html" %} +{% block title %}Mediation analysis{% endblock %} + +{% block content %} <!-- Start of body --> +<div class="container"> + <h1>Mediation analysis results</h1> + YAY ! We have our own route +</div> +{% endblock %} diff --git a/wqflask/wqflask/templates/phewas_analysis.html b/wqflask/wqflask/templates/phewas_analysis.html index ac163b43..2b04d85b 100644 --- a/wqflask/wqflask/templates/phewas_analysis.html +++ b/wqflask/wqflask/templates/phewas_analysis.html @@ -1,8 +1,9 @@ {% extends "base.html" %} -{% block title %}CTL analysis{% endblock %} +{% block title %}PheWAS analysis{% endblock %} {% block content %} <!-- Start of body --> <div class="container"> + <h1>PheWAS analysis results</h1> YAY ! We have our own route </div> {% endblock %} diff --git a/wqflask/wqflask/templates/show_trait_PheWAS_tools.html b/wqflask/wqflask/templates/show_trait_PheWAS_tools.html index ee4c5f5a..d8193652 100644 --- a/wqflask/wqflask/templates/show_trait_PheWAS_tools.html +++ b/wqflask/wqflask/templates/show_trait_PheWAS_tools.html @@ -40,7 +40,7 @@ </div> <div class="form-group"> <div style="padding-left:15px;" class="controls"> - <button id="phewas_compute" class="btn btn-primary submit_special" data-url="/phewas" title="Compute PheWAS"> + <button id="phewas_compute" class="btn btn-primary submit_special" title="Compute PheWAS"> <i class="icon-ok-circle icon-white"></i> Compute </button> </div> @@ -59,7 +59,7 @@ </div> <div class="form-group"> <div style="padding-left:15px;" class="controls"> - <button id="phewas_compute" class="btn submit_special btn-primary" data-url="/phewas" title="Compute PheWAS"> + <button id="ephewas_compute" class="btn submit_special btn-primary" title="Compute ePheWAS"> <i class="icon-ok-circle icon-white"></i> Compute </button> </div> @@ -78,13 +78,13 @@ </div> <div class="form-group"> <div style="padding-left:15px;" class="controls"> - <button id="phewas_compute" class="btn submit_special btn-primary" data-url="/phewas" title="Compute PheWAS"> + <button id="mediation_compute" class="btn submit_special btn-primary" title="Run mediation analysis"> <i class="icon-ok-circle icon-white"></i> Compute </button> </div> </div> </div> - </div> <!-- end of the ePheWAS tab --> + </div> <!-- end of the Mediation tab --> </div> </ul> |