# HG changeset patch # User iuc # Date 1656360479 0 # Node ID a941babb926863e6f4b33eb4e7c2034976d5d824 planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/samtools/samtools_ampliconclip commit 4596e7b08744df85b48d106cf4d44ebdd90dd554 diff -r 000000000000 -r a941babb9268 macros.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/macros.xml Mon Jun 27 20:07:59 2022 +0000 @@ -0,0 +1,256 @@ + + + + samtools + + + + 1.13 + 20.05 + + + + &2 && + gzip -dc \$reffa > reference.fa && + reffa="reference.fa" && + samtools faidx \$reffa; + } + } && + #end if + reffai=\$reffa.fai && + #elif $addref_cond.addref_select == "cached": + ## in case of cached the absolute path is used which allows to read + ## a cram file without specifying the reference + reffa='${addref_cond.ref.fields.path}' && + reffai=\$reffa.fai && + #else + #set use_ref=False + #end if + ]]> + + + + + @HELP@ + + + + + + + + + + + + + + + + + + + + + + @HELP@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^[^\s'\":]+(:\d+(-\d+){0,1}){0,1}$ + + + + + + + + + + + + + @misc{SAM_def, + title={Definition of SAM/BAM format}, + url = {https://samtools.github.io/hts-specs/},} + + 10.1093/bioinformatics/btp352 + 10.1093/bioinformatics/btr076 + 10.1093/bioinformatics/btr509 + + @misc{Danecek_et_al, + Author={Danecek, P., Schiffels, S., Durbin, R.}, + title={Multiallelic calling model in bcftools (-m)}, + url = {http://samtools.github.io/bcftools/call-m.pdf},} + + + @misc{Durbin_VCQC, + Author={Durbin, R.}, + title={Segregation based metric for variant call QC}, + url = {http://samtools.github.io/bcftools/rd-SegBias.pdf},} + + + @misc{Li_SamMath, + Author={Li, H.}, + title={Mathematical Notes on SAMtools Algorithms}, + url = {http://www.broadinstitute.org/gatk/media/docs/Samtools.pdf},} + + + @misc{SamTools_github, + title={SAMTools GitHub page}, + url = {https://github.com/samtools/samtools},} + + + + + &1 | grep Version]]> + + + + + + + diff -r 000000000000 -r a941babb9268 samtools_ampliconclip.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/samtools_ampliconclip.xml Mon Jun 27 20:07:59 2022 +0000 @@ -0,0 +1,83 @@ + + clip primer bases from bam files + + macros.xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +**What it does** + Clips read alignments where they match BED file defined regions (e.g. for amplicon sequencing). + + samtools ampliconclip -b [INPUT BED] [INPUT BAM1] -o [OUTPUT] + + + diff -r 000000000000 -r a941babb9268 test-data/eboVir3.1.bed --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/eboVir3.1.bed Mon Jun 27 20:07:59 2022 +0000 @@ -0,0 +1,3 @@ +eboVir3 500 1500 1 0 - +eboVir3 1500 2000 2 0 + +eboVir3 1500 3000 3 0 - diff -r 000000000000 -r a941babb9268 test-data/eboVir3.bam Binary file test-data/eboVir3.bam has changed diff -r 000000000000 -r a941babb9268 test-data/eboVir3.clipped.bam Binary file test-data/eboVir3.clipped.bam has changed diff -r 000000000000 -r a941babb9268 test-data/eboVir3.clipped.strand.bam Binary file test-data/eboVir3.clipped.strand.bam has changed diff -r 000000000000 -r a941babb9268 test-data/eboVir3.clipped.strand_gt30.bam Binary file test-data/eboVir3.clipped.strand_gt30.bam has changed diff -r 000000000000 -r a941babb9268 test-data/eboVir3.hardclipped.bam Binary file test-data/eboVir3.hardclipped.bam has changed diff -r 000000000000 -r a941babb9268 test-data/rebuild_output_bams.sh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/rebuild_output_bams.sh Mon Jun 27 20:07:59 2022 +0000 @@ -0,0 +1,4 @@ +samtools ampliconclip -b eboVir3.1.bed eboVir3.bam | samtools collate -@ 0 -O -u - | samtools fixmate -@ 0 -u - - | samtools sort -o eboVir3.clipped.bam +samtools ampliconclip --strand -b eboVir3.1.bed eboVir3.bam | samtools collate -@ 0 -O -u - | samtools fixmate -@ 0 -u - - | samtools sort -o eboVir3.clipped.strand.bam +samtools ampliconclip --hard-clip -b eboVir3.1.bed eboVir3.bam | samtools collate -@ 0 -O -u - | samtools fixmate -@ 0 -u - - | samtools sort -o eboVir3.hardclipped.bam +samtools ampliconclip --both-ends --no-excluded --strand --fail-len 30 -b eboVir3.1.bed eboVir3.bam | samtools collate -@ 0 -O -u - | samtools fixmate -@ 0 -u - - | samtools sort -o eboVir3.clipped.strand_gt30.bam