annotate CoverageReport.xml @ 24:fd788f9db899 draft

Added (default) option to collapse repetitive bed files
author geert-vandeweyer
date Thu, 12 Feb 2015 08:51:37 -0500
parents a718420c834e
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
19
6c7b09220992 new version 0.0.3 (fix on headless R)
geert-vandeweyer
parents: 18
diff changeset
1 <tool id="CoverageReport2" name="Panel Coverage Report" version="0.0.3">
0
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
2 <description></description>
4
2799221681dd Uploaded
geert-vandeweyer
parents: 0
diff changeset
3
0
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
4 <command interpreter="perl">
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
5 CoverageReport.pl
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
6 ## input files
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
7 -b $input1
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
8 -t $input2
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
9
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
10 ## output files
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
11 -o $output1
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
12 -z $output2
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
13
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
14 ## run parameters
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
15 $perGene
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
16 $PositionLevel
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
17 -m $threshold
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
18 -f $frac
23
a718420c834e Added (default) option to collapse repetitive BED files.
geert-vandeweyer
parents: 20
diff changeset
19 $trim
0
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
20 ## sample name
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
21 #if $namefromselect.namesource == "typed" :
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
22 -n "${namefromselect.typedname}"
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
23 #elif $namefromselect.namesource == "other":
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
24 -n "${namefromselect.namefile.display_name}"
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
25 #elif $namefromselect.namesource == "bam":
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
26 -n "${input1.display_name}"
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
27 #else:
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
28 -n "Unspecified"
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
29 #end if
23
a718420c834e Added (default) option to collapse repetitive BED files.
geert-vandeweyer
parents: 20
diff changeset
30
0
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
31 </command>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
32 <requirements>
20
b8e4ed167120 changed tool.xml to request R 3.0.3
geert-vandeweyer
parents: 19
diff changeset
33 <requirement type="package" version="3.0.3">R</requirement>
4
2799221681dd Uploaded
geert-vandeweyer
parents: 0
diff changeset
34 <requirement type="package" version="2.18.2">bedtools</requirement>
2799221681dd Uploaded
geert-vandeweyer
parents: 0
diff changeset
35 <requirement type="package" version="0.1.18">samtools</requirement>
0
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
36 </requirements>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
37 <inputs>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
38 <param name="input1" type="data" format="bam" label="BAM file" help="BAM file of mapped reads" />
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
39 <param name="input2" type="data" format="bed" label="Target Regions BED" help="BED file containing regions of interest. See below for format" />
23
a718420c834e Added (default) option to collapse repetitive BED files.
geert-vandeweyer
parents: 20
diff changeset
40 <param name="trim" type="select" label="Collapse overlapping regions in targets">
a718420c834e Added (default) option to collapse repetitive BED files.
geert-vandeweyer
parents: 20
diff changeset
41 <option value='-T' selected="TRUE">Yes</option>
a718420c834e Added (default) option to collapse repetitive BED files.
geert-vandeweyer
parents: 20
diff changeset
42 <option value=''>No</option>
a718420c834e Added (default) option to collapse repetitive BED files.
geert-vandeweyer
parents: 20
diff changeset
43 </param>
0
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
44 <param name="threshold" type="integer" value="40" label="Minimal Coverage Threshold" help="Default: 40" />
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
45 <param name="frac" type="float" value="0.2" label="Fraction of Average Coverage for usage in plot" help="Default: 0.2" />
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
46 <param name="perGene" type="select" label="Plot exon coverages for all genes in targets">
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
47 <option value='-r'>Yes</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
48 <option value=''>No</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
49 </param>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
50 <param name="PositionLevel" type="select" label="Perform Per Exon Analysis" help="Only Failed: Only those exons not reaching global coverage above threshold, or 100%. All Exons: This can take a very long time for large panels! Select all failed to check all exons for local failures." >
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
51 <option value='' selected="TRUE">None</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
52 <option value='-s'>Plot Only Globally Failed</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
53 <option value='-S'>Plot All Failed Exons</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
54 <option value='-A'>Plot All Exons</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
55 <option value='-L'>List All Failed Exons</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
56 </param>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
57 <conditional name="namefromselect">
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
58 <param name="namesource" type="select" label="Type the name of the sample or take the name of an input file?">
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
59 <option value="typed">Type the samplename</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
60 <option value="bam">Use the BAM File name</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
61 <option value="other">Select a file to base the name on</option>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
62 </param>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
63 <when value="typed">
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
64 <param name="typedname" type="text" size="25" label="Sample Name for Report." />
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
65 </when>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
66 <when value="other">
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
67 <param name="namefile" type="data" format="sam,bam,fastq,fasta,bed,fastqsanger,fastqillumina,text" label="Select a file from the history to base the sample name upon" />
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
68 </when>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
69 </conditional>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
70 </inputs>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
71 <outputs>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
72 <data format="pdf" name="output1" label="${tool.name} on ${on_string}: PDF Report"/>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
73 <data format="tar.gz" name="output2" label="${tool.name} on ${on_string}: Plots And Tables"/>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
74 </outputs>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
75 <help>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
76
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
77 **What it does**
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
78
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
79 This tool creates a coverage report for QC purposes. By default, average coverage statistics are provided, taken from samtools flagstats. If specified, it can also create overviews per gene in the BED file, and sub-exon plots for failed exons.
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
80
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
81 ------
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
82
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
83 **BED format**
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
84
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
85 The BED file containing targets of interest has very specific format requirements. You **must** use the following format::
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
86
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
87 Column 1: Chromosome : Use the same syntax as the references used by Galaxy. Check your sam-headers for the correct format. ('chr1' vs '1')
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
88 Column 2: Start Position
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
89 Column 3: End Position
19
6c7b09220992 new version 0.0.3 (fix on headless R)
geert-vandeweyer
parents: 18
diff changeset
90 Column 4: Target Name. Use : "GENE-NAME|Exon_number" : This is split on the pipe (or space) after 'GeneName' for correct grouping.Example: "CLIP2|Exon_4"
0
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
91 Column 5: Score : ignored, use '0'
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
92 Column 6: Strand: ignored,'+' or '-'
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
93
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
94 .. class:: infomark
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
95
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
96 Note: The exons for the plots will be ordered in the same way as the exons in the BED file.
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
97
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
98 ------
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
99
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
100 **Input formats**
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
101
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
102 BAM file for reads, BED file for targets.
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
103
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
104 ------
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
105
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
106 **Outputs**
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
107
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
108 The output files are a PDF report and a tar.gz file with all the plots and output tables.
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
109 The output tables are (tab seperated txt files):
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
110
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
111 **Targets.Global.Coverage** : Original BED file + following columns::
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
112 - Total coverage in target
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
113 - Bases in target with coverage
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
114 - Length of target
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
115 - Percent of target covered
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
116
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
117 **Targets.Position.Coverage** : Original BED file + following columns::
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
118 - Position in target region
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
119 - Coverage at position
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
120
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
121 </help>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
122 </tool>
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
123
ea32a329aced Initial Uploaded
geert-vandeweyer
parents:
diff changeset
124