Skip to content
Snippets Groups Projects
Commit a54b7305 authored by Floreal Cabanettes's avatar Floreal Cabanettes
Browse files

Add summary

parent 965d4e7e
No related branches found
No related tags found
No related merge requests found
This diff is collapsed.
{%- extends 'basic.tpl' -%}
{% from 'mathjax.tpl' import mathjax %}
{%- block header -%}
<!DOCTYPE html>
<html>
<head>
{%- block html_head -%}
<meta charset="utf-8" />
{% set nb_title = nb.metadata.get('title', '') or resources['metadata']['name'] %}
<title>{{nb_title}}</title>
{%- if "widgets" in nb.metadata -%}
<script src="https://unpkg.com/jupyter-js-widgets@2.0.*/dist/embed.js"></script>
{%- endif-%}
<script src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.1.10/require.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script>
{% for css in resources.inlining.css -%}
<style type="text/css">
{{ css }}
</style>
{% endfor %}
<style type="text/css">
/* Overrides of notebook CSS for static HTML export */
body {
overflow: visible;
padding: 8px;
}
div#notebook {
overflow: visible;
border-top: none;
}
{%- if resources.global_content_filter.no_prompt-%}
div#notebook-container{
padding: 6ex 12ex 8ex 12ex;
}
{%- endif -%}
@media print {
div.cell {
display: block;
page-break-inside: avoid;
}
div.output_wrapper {
display: block;
page-break-inside: avoid;
}
div.output {
display: block;
page-break-inside: avoid;
}
}
table > tbody > tr:nth-of-type(odd) {
background-color: #f9f9f9;
}
table, table td, table th, table tr {
border: none !important;
}
table th {
border-bottom: solid 1px black !important;
}
</style>
<!-- Custom stylesheet, it must be in the same directory as the html file -->
<link rel="stylesheet" href="custom.css">
<!-- Loading mathjax macro -->
{{ mathjax() }}
{%- endblock html_head -%}
</head>
{%- endblock header -%}
{% block body %}
<body>
<script>
function code_toggle() {
if (code_shown){
$('div.input').hide('500');
$('#toggleButton').val('Show Code')
} else {
$("div.input:not(:first)").show('500');
$('#toggleButton').val('Hide Code')
}
code_shown = !code_shown
}
$( document ).ready(function(){
code_shown=false;
$('div.input').hide()
});
</script>
<form action="javascript:code_toggle()" style="position:fixed;left:10px;top:10px"><input type="submit" id="toggleButton" value="Show Code"></form>
<div tabindex="-1" id="notebook" class="border-box-sizing">
<div class="container" id="notebook-container">
{{ super() }}
</div>
</div>
</body>
{%- endblock body %}
{% block footer %}
{{ super() }}
</html>
{% endblock footer %}
......@@ -59,7 +59,7 @@ def get_batches(wdir):
my_chrs.append(chrm)
if len(my_chrs) == 0:
raise WorkflowException("Filtered folder of batch %s does not containes files for variant %s!" % (file, variant))
raise WorkflowException("Filtered folder of batch %s does not contains files for variant %s!" % (file, variant))
if len(chromosomes) == 0:
chromosomes = my_chrs
else:
......@@ -97,7 +97,8 @@ localrules: all, bamlist
rule all:
input:
expand("filtered/{svtype}/svtyper_{chrom}_{svtype}_genotypes_filtered.vcf.gz", chrom=chromosomes, svtype=variant_types)
expand("filtered/{svtype}/svtyper_{chrom}_{svtype}_genotypes_filtered.vcf.gz", chrom=chromosomes, svtype=variant_types),
"Summarized_results.html"
rule prefilter:
input:
......@@ -173,3 +174,16 @@ rule filtering:
shell:
"filter.py -i {input.genotypes} -o {output.filtered} -g {params.genotyper} -k "
"1>{log.stdout} 2>{log.stderr}"
rule summary:
input:
"filtered/{svtype}/svtyper_{chrom}_{svtype}_genotypes_filtered.vcf.gz"
params:
tpl = os.path.join(ROOT_PATH, "full.tpl")
output:
ipynb = "Summarized_results.ipynb",
html = "Summarized_results.html"
threads:
1
shell:
jupyter nbconvert --to html --template {params.tpl} --execute {output.ipynb}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment