diff options
Diffstat (limited to 'gn2/wqflask/templates/show_trait_mapping_tools.html')
-rwxr-xr-x | gn2/wqflask/templates/show_trait_mapping_tools.html | 436 |
1 files changed, 436 insertions, 0 deletions
diff --git a/gn2/wqflask/templates/show_trait_mapping_tools.html b/gn2/wqflask/templates/show_trait_mapping_tools.html new file mode 100755 index 00000000..f1ed8922 --- /dev/null +++ b/gn2/wqflask/templates/show_trait_mapping_tools.html @@ -0,0 +1,436 @@ +<div class="main"> + {% if dataset.group.mapping_names|length > 0 %} + <div class="options"> + <div class="tabbable"> <!-- Only required for left/right tabs --> + + <ul class="nav nav-pills"> + {% for mapping_method in dataset.group.mapping_names %} + {% if mapping_method == "GEMMA" %} + <li class="gemma-tab mapping-tab {% if dataset.group.mapping_id == '1' or dataset.group.mapping_id == '2' %}active{% endif %}"> + <a href="#gemma" data-toggle="tab">GEMMA</a> + </li> + {% elif mapping_method == "R/qtl" %} + <li class="rqtl-geno-tab mapping-tab {% if dataset.group.mapping_id == '3' %}active{% endif %}"> + <a href="#rqtl_geno" data-toggle="tab">R/qtl</a> + </li> + <li class="rqtl-pair-tab mapping-tab"> + <a href="#rqtl_pair" data-toggle="tab">Pair Scan</a> + </li> + {% elif mapping_method == "QTLReaper" %} + <li class="reaper-tab mapping-tab"> + <a href="#interval_mapping" data-toggle="tab">Haley-Knott Regression</a> + </li> + {% endif %} + {% endfor %} + </ul> + + <div class="tab-content"> + {% for mapping_method in dataset.group.mapping_names %} + {% if mapping_method == "GEMMA" %} + <div class="tab-pane {% if dataset.group.mapping_id == '1' or dataset.group.mapping_id == '2' %}active{% endif %}" id="gemma"> + <div class="form-horizontal section-form-div"> + <div class="mapping_method_fields form-group"> + <label for="chr_select" class="col-xs-3 control-label">Chromosome</label> + <div class="col-xs-2 controls"> + <select id="chr_gemma" class="form-control chr-select"> + {% for item in chr_list %} + <option value="{{ item[1] }}">{{ item[0] }}</option> + {% endfor %} + </select> + </div> + </div> + {% if genofiles and genofiles|length>0 %} + <div class="mapping_method_fields form-group"> + <label for="genofiles" class="col-xs-3 control-label">Genotypes</label> + <div class="col-xs-6 controls"> + <select id="genofile_gemma" class="form-control"> + {% for item in genofiles %} + <option value="{{item['location']}}:{{item['title']}}">{{item['title']}}</option> + {% endfor %} + </select> + </div> + </div> + {% endif %} + <div class="mapping_method_fields form-group"> + <label for="maf_gemma" class="col-xs-3 control-label">Minor Allele ≥</label> + <div class="col-xs-4 controls"> + <input name="maf_gemma" value="{{ maf }}" type="text" class="form-control maf-select"> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label">Use LOCO</label> + <div class="col-xs-6 controls"> + <label class="radio-inline"> + <input type="radio" name="use_loco" value="True" checked=""> + Yes + </label> + <label class="radio-inline"> + <input type="radio" name="use_loco" value="False"> + No + </label> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label">Covariates<br><span class="covar-text">Select covariate(s) from a collection</span></label> + <div class="col-xs-8 covar-options"> + <div class="select-covar-div"> + <button type="button" class="btn btn-success select-covar-button select_covariates">Select</button> + <button type="button" class="btn btn-default select-covar-button remove_covariates">Remove</button> + <button type="button" class="btn btn-danger select-covar-button remove_all_covariates">Clear</button> + </div> + <select size="2" name="selected_covariates_gemma" class="form-control selected-covariates" multiple> + <option value="">No covariates selected</option> + </select> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label"></label> + <div class="col-xs-6"> + <button id="gemma_compute" type="button" class="btn submit_special btn-success" title="Compute Marker Regression" value="Compute" disabled>Loading...</button> + </div> + </div> + </div> + </div> + {% elif mapping_method == "QTLReaper" %} + <div class="tab-pane" id="interval_mapping"> + <div class="form-horizontal section-form-div"> + <div class="mapping_method_fields form-group"> + <label for="chr_select" class="col-xs-3 control-label">Chromosome</label> + <div class="col-xs-2 controls"> + <select id="chr_reaper" class="form-control chr-select"> + {% for item in chr_list %} + <option value="{{ item[1] }}">{{ item[0] }}</option> + {% endfor %} + </select> + </div> + </div> + {% if genofiles and genofiles|length>0 %} + <div class="mapping_method_fields form-group"> + <label for="scale_select" class="col-xs-3 control-label">Map Scale</label> + <div class="col-xs-2 controls"> + <select id="scale_reaper" class="form-control scale-select"> + {% for item in scales_in_geno[genofiles[0]['location']] %} + <option value="{{ item[0] }}">{{ item[1] }}</option> + {% endfor %} + </select> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label for="genofiles" class="col-xs-3 control-label">Genotypes</label> + <div class="col-xs-6 controls"> + <select id="genofile_reaper" class="form-control"> + {% for item in genofiles %} + <option value="{{item['location']}}:{{item['title']}}">{{item['title']}}</option> + {% endfor %} + </select> + </div> + </div> + {% else %} + <div class="mapping_method_fields form-group"> + <label for="scale_select" class="col-xs-3 control-label">Map Scale</label> + <div class="col-xs-2 controls"> + <select id="scale_reaper" class="form-control scale-select"> + {% for item in scales_in_geno[dataset.group.name + ".geno"] %} + <option value="{{ item[0] }}">{{ item[1] }}</option> + {% endfor %} + </select> + </div> + </div> + {% endif %} + <div class="mapping_method_fields form-group"> + <label for="mapping_permutations" class="col-xs-3 control-label">Permutations</label> + <div class="col-xs-4 controls"> + <input name="num_perm_reaper" value="1000" type="text" class="form-control"> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label for="mapping_bootstraps" class="col-xs-3 control-label">Bootstraps</label> + <div class="col-xs-4 controls"> + <input name="num_bootstrap" value="0" type="text" class="form-control"> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label for="control_for" class="col-xs-3 control-label">Control for<br>Cofactors</label> + <div class="col-xs-6 controls"> + <input name="control_reaper" value="{% if dataset.type == 'ProbeSet' and this_trait.locus_chr != '' %}{{ nearest_marker }}{% endif %}" type="text" class="form-control cofactor-input" /> + <br> + <label class="radio-inline"> + <input type="radio" name="do_control_reaper" value="true"> + Yes + </label> + <label class="radio-inline"> + <input type="radio" name="do_control_reaper" value="false" checked=""> + No + </label> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label">Interval Map</label> + <div class="col-xs-6 controls"> + <label class="radio-inline"> + <input type="radio" name="manhattan_plot_reaper" value="false" checked=""> + Yes + </label> + <label class="radio-inline"> + <input type="radio" name="manhattan_plot_reaper" value="true"> + No + </label> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label"></label> + <div class="col-xs-6"> + <button id="interval_mapping_compute" type="button" class="btn submit_special btn-success" title="Compute Interval Mapping" value="Compute" disabled>Loading...</button> + </div> + </div> + </div> + </div> + {% elif mapping_method == "R/qtl" %} + <div class="tab-pane {% if dataset.group.mapping_id == '3' %}active{% endif %}" id="rqtl_geno"> + <div class="form-horizontal section-form-div"> + <div class="mapping_method_fields form-group"> + <label for="chr_select" class="col-xs-3 control-label">Chromosome</label> + <div class="col-xs-2 controls"> + <select id="chr_rqtl_geno" class="form-control chr-select"> + {% for item in chr_list %} + <option value="{{ item[1] }}">{{ item[0] }}</option> + {% endfor %} + </select> + </div> + </div> + {% if genofiles and genofiles|length > 0 %} + <div class="mapping_method_fields form-group"> + <label for="scale_select" class="col-xs-3 control-label">Map Scale</label> + <div class="col-xs-2 controls"> + <select id="scale_rqtl_geno" class="form-control scale-select"> + {% for item in scales_in_geno[genofiles[0]['location']] %} + <option value="{{ item[0] }}">{{ item[1] }}</option> + {% endfor %} + </select> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label for="genofiles" class="col-xs-3 control-label">Genotypes</label> + <div class="col-xs-6 controls"> + <select id="genofile_rqtl_geno" class="form-control"> + {% for item in genofiles %} + <option value="{{item['location']}}:{{item['title']}}">{{item['title']}}</option> + {% endfor %} + </select> + </div> + </div> + {% else %} + <div class="mapping_method_fields form-group"> + <label for="scale_select" class="col-xs-3 control-label">Map Scale</label> + <div class="col-xs-2 controls"> + <select id="scale_rqtl_geno" class="form-control scale-select"> + {% for item in scales_in_geno[dataset.group.name + ".geno"] %} + <option value="{{ item[0] }}">{{ item[1] }}</option> + {% endfor %} + </select> + </div> + </div> + {% endif %} + <div class="mapping_method_fields form-group"> + <label for="mapping_permutations" class="col-xs-3 control-label">Permutations</label> + <div class="col-xs-4 controls"> + <input name="num_perm_rqtl_geno" value="200" type="text" class="form-control"> + </div> + </div> + {% if sample_groups[0].attributes|length > 0 %} + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label">Stratified</label> + <div class="col-xs-6 controls"> + <label class="radio-inline"> + <input type="radio" name="perm_strata" value="True" checked=""> + Yes + </label> + <label class="radio-inline"> + <input type="radio" name="perm_strata" value="False" > + No + </label> + </div> + </div> + {% endif %} + <div class="mapping_method_fields form-group"> + <label for="mapmodel_rqtl_geno" class="col-xs-3 control-label">Model</label> + <div class="col-xs-4 controls"> + <select id="mapmodel_rqtl_geno" name="mapmodel_rqtl_geno" class="form-control"> + <option value="normal">Normal</option> + {% if binary == "true" %}<option value="binary">Binary</option>{% endif %} + <!--<option value="2part">2-part</option>--> + <option value="np">Non-parametric</option> + </select> + </div> + </div> + + <div class="mapping_method_fields form-group"> + <label for="mapmethod_rqtl_geno" class="col-xs-3 control-label">Method</label> + <div class="col-xs-6 controls"> + <select id="mapmethod_rqtl_geno" name="mapmethod_rqtl_geno" class="form-control"> + <option value="hk" selected>Haley-Knott</option> + <option value="ehk">Extended Haley-Knott</option> + <option value="mr">Marker Regression</option> + <option value="em">Expectation-Maximization</option> + <option value="imp">Imputation</option> + </select> + </div> + </div> + <div id="missing_geno_div" class="mapping_method_fields form-group" style="display: none;"> + <label for="missing_genotypes" class="col-xs-3 control-label"></label> + <div class="col-xs-6 controls"> + <select id="missing_genotype" name="missing_genotypes" class="form-control"> + <option value="mr">Remove Samples w/o Genotypes</option> + <option value="mr-imp">Single Imputation</option> + <option value="mr-argmax">Imputation w/ Viterbi Algorithm</option> + </select> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label">Manhattan<br>Plot</label> + <div class="col-xs-6 controls"> + <label class="radio-inline"> + <input type="radio" name="manhattan_plot_rqtl" value="True"> + Yes + </label> + <label class="radio-inline"> + <input type="radio" name="manhattan_plot_rqtl" value="False" checked=""> + No + </label> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label">Covariates<br><span class="covar-text">Select covariate(s) from a collection</span></label> + <div class="col-xs-8 covar-options"> + <div class="select-covar-div"> + <button type="button" class="btn btn-success select-covar-button select_covariates">Select</button> + <button type="button" class="btn btn-default select-covar-button remove_covariates">Remove</button> + <button type="button" class="btn btn-danger select-covar-button remove_all_covariates">Clear</button> + </div> + <select size="2" name="selected_covariates_rqtl" class="form-control selected-covariates" multiple> + <option value="">No covariates selected</option> + </select> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label"></label> + <div class="col-xs-6 controls"> + <button id="rqtl_geno_compute" type="button" class="btn submit_special btn-success" title="Compute Marker Regression" value="Compute" disabled>Loading...</button> + </div> + </div> + </div> + </div> + <div class="tab-pane" id="rqtl_pair"> + <div class="form-horizontal section-form-div"> + {% if genofiles and genofiles|length > 0 %} + <div class="mapping_method_fields form-group"> + <label for="genofiles" class="col-xs-3 control-label">Genotypes</label> + <div class="col-xs-6 controls"> + <select id="genofile_rqtl_pair" class="form-control"> + {% for item in genofiles %} + <option value="{{item['location']}}:{{item['title']}}">{{item['title']}}</option> + {% endfor %} + </select> + </div> + </div> + {% endif %} + <div class="mapping_method_fields form-group"> + <label for="control_for" class="col-xs-3 control-label">Control for</label> + <div class="col-xs-6 controls"> + <input name="control_rqtl_pair" value="{% if dataset.type == 'ProbeSet' and this_trait.locus_chr != '' %}{{ nearest_marker }}{% endif %}" type="text" class="form-control cofactor-input" /> + <label class="radio-inline"> + <input type="radio" name="do_control_rqtl" value="true"> + Yes + </label> + <label class="radio-inline"> + <input type="radio" name="do_control_rqtl" value="false" checked=""> + No + </label> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label for="mapmodel_rqtl_pair" class="col-xs-3 control-label">Model</label> + <div class="col-xs-4 controls"> + <select id="mapmodel_rqtl_pair" name="mapmodel_rqtl_pair" class="form-control"> + <option value="normal">Normal</option> + {% if binary == "true" %}<option value="binary">Binary</option>{% endif %} + <!--<option value="2part">2-part</option>--> + <option value="np">Non-parametric</option> + </select> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label for="mapmethod_rqtl_pair" class="col-xs-3 control-label">Method</label> + <div class="col-xs-6 controls"> + <select id="mapmethod_rqtl_pair" name="mapmethod_rqtl_pair" class="form-control"> + <option value="hk" selected>Haley-Knott</option> + <option value="ehk">Extended Haley-Knott</option> + <option value="mr">Marker Regression</option> + <option value="em">Expectation-Maximization</option> + <option value="imp">Imputation</option> + </select> + </div> + </div> + <div id="missing_geno_pair_div" class="mapping_method_fields form-group" style="display: none;"> + <label for="missing_genotypes_pair" class="col-xs-3 control-label"></label> + <div class="col-xs-6 controls"> + <select id="missing_genotype_pair" name="missing_genotypes" class="form-control"> + <option value="mr">Remove Samples w/o Genotypes</option> + <option value="mr-imp">Single Imputation</option> + <option value="mr-argmax">Imputation w/ Viterbi Algorithm</option> + </select> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label">Covariates<br><span class="covar-text">Select covariate(s) from a collection</span></label> + <div class="col-xs-8 covar-options"> + <div class="select-covar-div"> + <button type="button" class="btn btn-default select-covar-button select_covariates">Select</button> + <button type="button" class="btn btn-default select-covar-button remove_covariates">Remove</button> + </div> + <textarea rows="3" cols="50" readonly placeholder="No covariates selected" class="selected-covariates"></textarea> + </div> + </div> + <div class="mapping_method_fields form-group"> + <label class="col-xs-3 control-label"></label> + <div class="col-xs-6 controls"> + <button id="rqtl_pair_compute" type="button" class="btn submit_special btn-success" data-url="/marker_regression" title="Compute Pair Scan" value="Compute" disabled>Loading...</button> + </div> + </div> + </div> + </div> + {% endif %} + {% endfor %} + </div> + </div> + </div> + <div class="descriptions"> + <div class="section-form-div"> + <dl> + {% for mapping_method in dataset.group.mapping_names %} + {% if mapping_method == "GEMMA" %} + <dt>GEMMA</dt> + <dd>GEMMA maps with correction for kinship using a linear mixed model and can include covariates such as sex and age. Defaults include a minor allele frequency of 0.05 and the leave-one-chromosome-out method (<a href="https://www.ncbi.nlm.nih.gov/pubmed/24531419">PMID: 2453419</a>, and <a href="https://github.com/genetics-statistics/GEMMA"> GitHub code</a>).</dd> + {% elif mapping_method == "R/qtl" %} + <dt class="map-method-text">R/qtl (version 1.44.9)</dt> + <dd><a href="https://www.ncbi.nlm.nih.gov/pubmed/12724300">R/qtl</a> maps using several models and uniquely support 4-way intercrosses such as the "Aging Mouse Lifespan Studies" (NIA UM-HET3). We will add support for R/qtl2 (<a href="https://www.ncbi.nlm.nih.gov/pubmed/30591514">PMID: 30591514</a>) in 2023—a version that handles complex populations with admixture and many haplotypes.</dd> + <dt class="map-method-text">Pair Scan (R/qtl v 1.44.9)</dt> + <dd>The Pair Scan mapping tool performs a search for joint effects of two separate loci that may influence a trait. This search typically requires large sample sizes. Pair Scans can included covariates such as age and sex. For more on this function by K. Broman and colleagues see www.rdocumentation.org/packages/qtl/versions/1.60/topics/scantwo</dd> + {% elif mapping_method == "QTLReaper" %} + <dt class="map-method-text">Haley-Knott Regression</dt> + <dd>HK regression (QTL Reaper) is a fast mapping method with permutation that works well with F2 intercrosses and backcrosses (<a href="https://www.ncbi.nlm.nih.gov/pubmed/16718932">PMID 16718932</a>), but is not recommended for admixed populations, advanced intercrosses, or strain families such as the BXDs (<a href="https://github.com/pjotrp/QTLReaper">QTL Reaper code</a>).</dd> + {% endif %} + {% endfor %} + </dl> + <div class="rqtl-description"> + More information on R/qtl mapping models and methods can be found <a href="http://www.rqtl.org/tutorials/rqtltour.pdf">here</a>. + </div> + </div> + </div> + <div id="mapping_result_holder_wrapper" style="display:none;"> + <div id="mapping_result_holder"></div> + </div> + {% else %} + Mapping options are disabled for data not matched with genotypes. + {% endif %} +</div> |