aboutsummaryrefslogtreecommitdiff
path: root/gn2/wqflask/templates/marker_regression.html
diff options
context:
space:
mode:
authorAlexander_Kabui2024-01-02 13:21:07 +0300
committerAlexander_Kabui2024-01-02 13:21:07 +0300
commit70c4201b332e0e2c0d958428086512f291469b87 (patch)
treeaea4fac8782c110fc233c589c3f0f7bd34bada6c /gn2/wqflask/templates/marker_regression.html
parent5092eb42f062b1695c4e39619f0bd74a876cfac2 (diff)
parent965ce5114d585624d5edb082c710b83d83a3be40 (diff)
downloadgenenetwork2-70c4201b332e0e2c0d958428086512f291469b87.tar.gz
merge changes
Diffstat (limited to 'gn2/wqflask/templates/marker_regression.html')
-rw-r--r--gn2/wqflask/templates/marker_regression.html119
1 files changed, 119 insertions, 0 deletions
diff --git a/gn2/wqflask/templates/marker_regression.html b/gn2/wqflask/templates/marker_regression.html
new file mode 100644
index 00000000..b633f815
--- /dev/null
+++ b/gn2/wqflask/templates/marker_regression.html
@@ -0,0 +1,119 @@
+{% from "base_macro.html" import header %}
+{% block content %}
+ {{ header("Mapping",
+ '{}: {}'.format(this_trait.name, this_trait.description_fmt)) }}
+
+ <div class="container">
+ <div>
+ <h2>
+ Whole Genome Mapping
+ </h2>
+ <form style ='float: left; padding: 5px;' id="exportform" action="export" method="post">
+ <input type="hidden" id="data" name="data" value="">
+ <input type="hidden" id="filename" name="filename" value="">
+ <input type="submit" id="export" value="Download SVG">
+ </form>
+ <form style ='float: left; padding: 5px;' id="exportpdfform" action="export_pdf" method="post">
+ <input type="hidden" id="data" name="data" value="">
+ <input type="hidden" id="filename" name="filename" value="">
+ <input type="submit" id="export_pdf" value="Download PDF">
+ </form>
+ <button id="return_to_full_view" class="btn" style="display:none">Return to full view</button>
+ </div>
+ <div id="chart_container">
+ <div class="qtlcharts" id="topchart">
+
+ </div>
+ </div>
+ <div style="width:60%;">
+ <h2>
+ Results
+ </h2>
+ <table id="qtl_results" class="table table-hover table-striped">
+ <thead>
+ <tr>
+ <th></th>
+ <th>Index</th>
+ <th>{{ score_type }}</th>
+ <th>Chr</th>
+ {% if mapping_scale == "centimorgan" %}
+ <th>cM</th>
+ {% else %}
+ <th>Mb</th>
+ {% endif %}
+ <th>Locus</th>
+ </tr>
+ </thead>
+ <tbody>
+ {% for marker in qtl_results %}
+ {% if (score_type == "LOD" and marker.lod_score > cutoff) or
+ (score_type == "LRS" and marker.lrs_value > cutoff) %}
+ <tr>
+ <td>
+ <input type="checkbox" name="selectCheck"
+ class="checkbox edit_sample_checkbox"
+ value="{{ marker.name }}" checked="checked">
+ </td>
+ <Td align="right">{{ loop.index }}</Td>
+ {% if score_type == "LOD" %}
+ <td>{{ '%0.2f' | format(marker.lod_score|float) }}</td>
+ {% else %}
+ <td>{{ '%0.2f' | format(marker.lrs_value|float) }}</td>
+ {% endif %}
+ <td>{{marker.chr}}</td>
+ <td>{{ '%0.6f' | format(marker.Mb|float) }}</td>
+ <td>
+ {{ marker.name }}
+ <!--<a href="{{ url_for('show_trait_page',
+ trait_id = marker.name,
+ dataset = dataset.name
+ )}}">
+ {{ marker.name }}
+ </a>-->
+ </td>
+ </tr>
+ {% endif %}
+ {% endfor %}
+ </tbody>
+ </table>
+ </div>
+ </div>
+
+ <!-- End of body -->
+
+{% endblock %}
+
+{% block js %}
+ <script>
+ js_data = {{ js_data | safe }}
+ </script>
+
+ <script type="text/javascript" charset="utf-8">
+ $(document).ready( function () {
+ console.time("Creating table");
+ $('#qtl_results').dataTable( {
+ "columns": [
+ { "type": "natural", "bSortable": false },
+ { "type": "natural" },
+ { "type": "natural" },
+ { "type": "natural" },
+ { "type": "natural" },
+ { "type": "natural" }
+ ],
+ "buttons": [
+ 'csv'
+ ],
+ "sDom": "RZBtir",
+ "iDisplayLength": -1,
+ "autoWidth": true,
+ "bDeferRender": true,
+ "bSortClasses": false,
+ "scrollY": "700px",
+ "scrollCollapse": true,
+ "paging": false
+ } );
+ console.timeEnd("Creating table");
+
+ });
+ </script>
+{% endblock %}