-
Notifications
You must be signed in to change notification settings - Fork 6
/
gatk_bqsr.xml
66 lines (56 loc) · 1.92 KB
/
gatk_bqsr.xml
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
<tool id="gatk_bqsr" name="GATK BQSR" version="1.0.0">
<description>base quality score recalibration</description>
<requirements>
<container type="docker">gatk</container>
</requirements>
<command interpreter="bash">$runscript</command>
<inputs>
<param format="bam" type="data" name="input_bam" label="Input BAM" help="" />
<param format="vcf" type="data" name="known_sites" label="Known SNP sites VCF" />
<param format="fasta" type="data" name="reference" label="Reference Genome" />
<param type="boolean" name="emit_oq" label="Emit Original Quality Scores" truevalue="--emit_original_quals" falsevalue="" checked="yes"/>
</inputs>
<outputs>
<data format="txt" name="output_report" label="BQSR Report" from_work_dir="recal_data.table"/>
<data format="bam" name="output_bam" label="BQSR BAM" from_work_dir="output.bam"/>
</outputs>
<configfiles>
<configfile name="runscript">#!/bin/bash
set -e
ln -s ${input_bam} input.bam
ln -s ${input_bam.metadata.bam_index} input.bam.bai
ln -s ${reference} reference.fasta
ln -s ${known_sites} known_sites.vcf
samtools faidx reference.fasta
java -jar /opt/picard/CreateSequenceDictionary.jar R=reference.fasta O=reference.dict
java -jar /opt/GenomeAnalysisTK.jar \
-T BaseRecalibrator \
-R reference.fasta \
-I input.bam \
-knownSites known_sites.vcf \
-nct \${GALAXY_SLOTS:-4} \
-o recal_data.table
java -jar /opt/GenomeAnalysisTK.jar \
-T PrintReads \
-R reference.fasta \
${emit_oq} \
-I input.bam \
-nct \${GALAXY_SLOTS:-4} \
-BQSR recal_data.table \
-o output.bam
</configfile>
</configfiles>
<stdio>
<exit_code range="1:" level="fatal" />
<regex match="ERROR"
source="both"
level="fatal"
description="Error running BQSR" />
</stdio>
<help>
</help>
<tests>
<test>
</test>
</tests>
</tool>