Mercurial > repos > devteam > freebayes
annotate leftalign.xml @ 21:978760187fe2 draft
planemo upload commit 4ec9eb1570ea116d83f5464a786af6e14fb5b57d
author | devteam |
---|---|
date | Fri, 09 Oct 2015 15:47:24 -0400 |
parents | 55c06df02168 |
children | 52aed7d9ed2b |
rev | line source |
---|---|
16 | 1 <?xml version="1.0"?> |
19 | 2 <tool id="bamleftalign" name="BamLeftAlign" version="0.4"> |
16 | 3 <requirements> |
19 | 4 <requirement type="package" version="0_9_20_b040236">freebayes</requirement> |
16 | 5 <requirement type="package" version="0.1.18">samtools</requirement> |
6 </requirements> | |
7 <description> indels in BAM datasets</description> | |
8 <command> | |
9 ##set up input files | |
10 #set $reference_fasta_filename = "localref.fa" | |
11 #if str( $reference_source.reference_source_selector ) == "history": | |
12 ln -s "${reference_source.ref_file}" "${reference_fasta_filename}" && | |
13 samtools faidx "${reference_fasta_filename}" 2>&1 || echo "Error running samtools faidx for leftalign" >&2 && | |
14 #else: | |
15 #set $reference_fasta_filename = str( $reference_source.ref_file.fields.path ) | |
16 #end if | |
17 | |
18 ##finished setting up inputs | |
19 | |
20 ##start leftalign commandline | |
21 samtools view -bh "${input_bam}" | bamleftalign | |
22 --fasta-reference "${reference_fasta_filename}" | |
23 -c | |
24 --max-iterations "${iterations}" | |
25 ##outputs | |
26 > "${output_bam}" | |
27 </command> | |
28 <inputs> | |
29 <conditional name="reference_source"> | |
30 <param name="reference_source_selector" type="select" label="Choose the source for the reference list"> | |
31 <option value="cached">Locally cached</option> | |
32 <option value="history">History</option> | |
33 </param> | |
34 <when value="cached"> | |
35 <param name="input_bam" type="data" format="bam" label="Select BAM dataset to leftalign"> | |
36 <validator type="unspecified_build" /> | |
37 <validator type="dataset_metadata_in_data_table" table_name="fasta_indexes" metadata_name="dbkey" metadata_column="1" message="Sequences are not currently available for the specified build." /> | |
38 </param> | |
39 <param name="ref_file" type="select" label="Using reference genome"> | |
40 <options from_data_table="fasta_indexes"></options> | |
41 <validator type="no_options" message="A built-in reference genome is not available for the build associated with the selected input file"/> | |
42 </param> | |
43 </when> | |
44 <when value="history"> | |
45 <param name="input_bam" type="data" format="bam" label="BAM dataset to re-align" /> | |
46 <param name="ref_file" type="data" format="fasta" label="Using reference file" /> | |
47 </when> | |
48 </conditional> | |
21
978760187fe2
planemo upload commit 4ec9eb1570ea116d83f5464a786af6e14fb5b57d
devteam
parents:
19
diff
changeset
|
49 <param name="iterations" type="integer" value="5" label="Maximum number of iterations" help="Iterate the left-realignment no more than this many times" /> |
16 | 50 </inputs> |
51 <outputs> | |
52 <data format="bam" name="output_bam" label="${tool.name} on ${on_string} (alignments)" /> | |
53 </outputs> | |
54 <tests> | |
55 <test> | |
56 <param name="reference_source_selector" value="history" /> | |
57 <param name="ref_file" ftype="fasta" value="leftalign.fa"/> | |
58 <param name="input_bam" ftype="bam" value="left-align-input.bam"/> | |
59 <param name="iterations" value="5"/> | |
60 <output name="output_bam" file="left-align-output.bam" /> | |
61 </test> | |
62 </tests> | |
63 <stdio> | |
64 <exit_code range="1:" /> | |
65 </stdio> | |
66 <help> | |
67 | |
68 When calling indels, it is important to homogenize the positional distribution of insertions and deletions in the input by using left realignment. Left realignment will place all indels in homopolymer and microsatellite repeats at the same position, provided that doing so does not introduce mismatches between the read and reference other than the indel. This method is computationally inexpensive and handles the most common classes of alignment inconsistency. | |
69 | |
70 This is leftalign utility from FreeBayes package developed and maintained by Erik Garrison (https://github.com/ekg/freebayes). | |
71 </help> | |
72 | |
73 <citations> | |
74 <citation type="bibtex"> | |
75 @misc{1207.3907, | |
76 Author = {Erik Garrison}, | |
77 Title = {Haplotype-based variant detection from short-read sequencing}, | |
78 Year = {2012}, | |
79 Eprint = {arXiv:1207.3907}, | |
80 url = {http://arxiv.org/abs/1207.3907} | |
81 } | |
82 </citation> | |
83 </citations> | |
84 | |
85 </tool> |