jpayne@0
|
1 <tool id="call_consensus" name="5. Call consensus SNPs" version="1.0.1" profile="16.10">
|
jpayne@0
|
2 <description>for a sample, or lookup cached consensus SNP calls</description>
|
jpayne@0
|
3 <requirements>
|
jpayne@61
|
4 <!-- <container type="docker">quay.io/biocontainers/mulled-v2-fe715cf36e5a6063362b28e50f1f4a1a767770d5:8f94687b7d8826f1473b7e97df0cea2a960b35bf-0</container> -->
|
jpayne@61
|
5 <requirement type="package" version="1.0.8">bzip2</requirement>
|
jpayne@58
|
6 <requirement type="package" version="2.2.1">snp-pipeline</requirement>
|
jpayne@61
|
7 <!-- <requirement type="package" version="1.9.134">boto3</requirement> -->
|
jpayne@58
|
8 <!-- <requirement type="package" version="3.6.8">python</requirement> -->
|
jpayne@0
|
9 </requirements>
|
jpayne@0
|
10 <command detect_errors="exit_code"><![CDATA[
|
jpayne@40
|
11 export LD_LIBRARY_PATH="\$CONDA_DEFAULT_ENV/lib" &&
|
jpayne@0
|
12 #set $identifier = $call_pileup.name.split(' ')[0]
|
jpayne@50
|
13 python $__tool_directory__/snp-cache.py snp_consenus_calls
|
jpayne@0
|
14 "\$(md5sum $snps $calls $call_pileup | cut -c -32 | md5sum | cut -c -32)"
|
jpayne@0
|
15 -c "
|
jpayne@50
|
16 mkdir -p ./$identifier/
|
jpayne@0
|
17 && cp $call_pileup ./$identifier/reads.all.pileup
|
jpayne@0
|
18 && cfsan_snp_pipeline call_consensus -v 4 -l $snps --vcfFileName "consensus.vcf" ./$identifier/reads.all.pileup 1>&2 && tar zcv ./consensus.vcf ./consensus.fasta
|
jpayne@0
|
19 "
|
jpayne@0
|
20 -l $cache_log
|
jpayne@0
|
21 | tar zvx ./
|
jpayne@0
|
22 && cp ./consensus.fasta $calls_consensus_fa
|
jpayne@0
|
23 && cp ./consensus.vcf $calls_consensus_vcf
|
jpayne@0
|
24 && cat $cache_log
|
jpayne@0
|
25 ]]></command>
|
jpayne@0
|
26 <inputs>
|
jpayne@0
|
27 <param type="data" name="snps" format="txt" />
|
jpayne@0
|
28 <param type="data" name="calls" format="vcf" />
|
jpayne@0
|
29 <param type="data" name="call_pileup" format="pileup" />
|
jpayne@0
|
30 </inputs>
|
jpayne@0
|
31 <outputs>
|
jpayne@0
|
32 <data label="${calls.name.split(' ')[0]} consensus SNPs (VCF)" name="calls_consensus_vcf" format="vcf" />
|
jpayne@0
|
33 <data label="${calls.name.split(' ')[0]} consensus SNPs (FASTA)" name="calls_consensus_fa" format="fasta" hidden="true"/>
|
jpayne@0
|
34 <data label="S3 Cache log" name="cache_log" format="txt" hidden="true" />
|
jpayne@0
|
35 </outputs>
|
jpayne@0
|
36 <tests>
|
jpayne@0
|
37 <test>
|
jpayne@0
|
38 <param name="snps" value="snplist.txt" />
|
jpayne@0
|
39 <param name="calls" value="samples/sample1/var.flt.vcf" />
|
jpayne@0
|
40 <param name="call_pileup" value="samples/sample1/reads.all.pileup" />
|
jpayne@50
|
41 <output name="calls_consensus_vcf" value="samples/sample1/consensus.vcf" lines_diff="20" />
|
jpayne@0
|
42 <output name="calls_consensus_fa" value="samples/sample1/consensus.fasta" lines_diff="2" />
|
jpayne@0
|
43 </test>
|
jpayne@0
|
44 </tests>
|
jpayne@0
|
45 <help><![CDATA[
|
jpayne@0
|
46 <a href="http://snp-pipeline.readthedocs.io/en/latest/index.html">http://snp-pipeline.readthedocs.io/en/latest/index.html</a>
|
jpayne@0
|
47 ]]></help>
|
jpayne@0
|
48 <citations>
|
jpayne@0
|
49 <citation type="doi">10.7717/peerj-cs.20</citation>
|
jpayne@0
|
50 </citations>
|
jpayne@0
|
51 </tool> |