1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
|
{% extends "base.html" %}
{% block css %}
<link rel="stylesheet" type="text/css" href="/static/packages/jqplot/jquery.jqplot.min.css" />
<link rel="stylesheet" type="text/css" href="/static/new/packages/DataTables/css/jquery.dataTables.css" />
<link rel="stylesheet" type="text/css" href="/static/packages/DT_bootstrap/DT_bootstrap.css" />
<link rel="stylesheet" type="text/css" href="/static/packages/TableTools/media/css/TableTools.css" />
{% endblock %}
{% block content %}
{{ header("Correlation", 'Trait: {} Dataset: {}'.format(this_trait.name, dataset.name)) }}
<table id="corr_results" class="table table-hover table-striped table-bordered">
<thead>
<tr>
<th>Trait</th>
<th>Symbol</th>
<th>Alias</th>
<th>Description</th>
<th>Location</th>
<th>Mean Expr</th>
<th>Max LRS</th>
<th>Max LRS Location</th>
{% if corr_method == 'pearson' %}
<th>Sample r</th>
<th>N Cases</th>
<th>Sample p(r)</th>
<th>Lit Corr</th>
<th>Tissue r</th>
<th>Tissue p(r)</th>
{% else %}
<th>Sample rho</th>
<th>Sample p(rho)</th>
<th>Lit Corr</th>
<th>Tissue rho</th>
<th>Tissue p(rho)</th>
{% endif %}
</tr>
</thead>
<tbody>
{% for trait in correlation_results %}
<tr>
<td><a href="/show_trait?trait_id={{trait.name}}&dataset={{trait.dataset.name}}">{{ trait.name }}</a></td>
<td>{{ trait.symbol }}</td>
<td>{{ trait.alias }}</td>
<td>{{ trait.description }}</td>
<td>Chr{{ trait.chr }}:{{trait.mb}}</td>
<td>{{'%0.3f'|format(trait.mean)}}</td>
<td>{{'%0.3f'|format(trait.lrs)}}</td>
<td>Chr{{ trait.locus_chr }}:{{'%0.6f'|format(trait.locus_mb)}}</td>
<td><a href="corr_scatter_plot?dataset_1={{dataset.name}}&dataset_2={{trait.dataset.name}}&trait_1={{this_trait.name}}&trait_2={{trait.name}}&">{{'%0.3f'|format(trait.sample_r)}}</a></td>
<td>{{ trait.num_overlap }}</td>
<td>{{'%0.3e'|format(trait.sample_p)}}</td>
<td>{{'%0.3f'|format(trait.lit_corr)}}</td>
<td>{{'%0.3f'|format(trait.tissue_corr)}}</td>
<td>{{'%0.3e'|format(trait.tissue_pvalue)}}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endblock %}
{% block js %}
<script language="javascript" type="text/javascript" src="/static/new/packages/DataTables/js/jquery.js"></script>
<script language="javascript" type="text/javascript" src="/static/new/packages/DataTables/js/jquery.dataTables.min.js"></script>
<script language="javascript" type="text/javascript" src="/static/packages/DT_bootstrap/DT_bootstrap.js"></script>
<script language="javascript" type="text/javascript" src="/static/packages/TableTools/media/js/TableTools.min.js"></script>
<script language="javascript" type="text/javascript" src="/static/packages/underscore/underscore-min.js"></script>
<script type="text/javascript" charset="utf-8">
$(document).ready( function () {
console.time("Creating table");
$('#corr_results').dataTable( {
//"sDom": "<<'span3'l><'span3'T><'span4'f>'row-fluid'r>t<'row-fluid'<'span6'i><'span6'p>>",
"sDom": "lTftipr",
"oTableTools": {
"aButtons": [
"copy",
"print",
{
"sExtends": "collection",
"sButtonText": 'Save <span class="caret" />',
"aButtons": [ "csv", "xls", "pdf" ]
}
],
"sSwfPath": "/static/packages/TableTools/media/swf/copy_csv_xls_pdf.swf"
},
"iDisplayLength": 50,
"bLengthChange": true,
"bDeferRender": true,
"bSortClasses": false
} );
console.timeEnd("Creating table");
});
</script>
{% endblock %}
|