Samtools and idxstats
Hi, I would like to inquire whether anyone has attempted to implement the idxstats tool from samtools into Galaxy? The xml-file for idxstats is not present in the Galaxy source code, which led me to try and implement it myself. However, the main problem I face is that the idxstats tool silently relies on having an index file available (within the same directory) for the bam file you which to print the stats for. E.g. samtools idxstats PATH/test.bam searches for PATH/test.bam.bai and gives an error when this file is not present. And somehow I cannot model this behavior in Galaxy. A different solution would of course be to ask the author(s) of samtools to have an option available where the user can directly indicate the path to the index file. regards, Michiel PS: I've searched the mailing list archives for this problem but did not find any matches. Apologies if I somehow missed the answer. -- ================================================================== Michiel Van Bel, PhD Expert Bioinformatician Tel:+32 (0)9 331 36 95 fax:+32 (0)9 3313809 VIB Department of Plant Systems Biology, Ghent University Technologiepark 927, 9052 Gent, BELGIUM mibel@psb.vib-ugent.be http://www.psb.vib-ugent.be http://bioinformatics.psb.ugent.be ==================================================================
Galaxy stores a BAI for each BAM internally; you can access it in a tool wrapper like this (assuming the name of your input dataset is 'input_bam': ${input_bam.metadata.bam_index} Once you have the file path, you can set up a symbolic link to it and the tool should work fine. Good luck, J. On May 22, 2013, at 4:05 AM, Michiel Van Bel wrote:
Hi,
I would like to inquire whether anyone has attempted to implement the idxstats tool from samtools into Galaxy? The xml-file for idxstats is not present in the Galaxy source code, which led me to try and implement it myself. However, the main problem I face is that the idxstats tool silently relies on having an index file available (within the same directory) for the bam file you which to print the stats for. E.g. samtools idxstats PATH/test.bam searches for PATH/test.bam.bai and gives an error when this file is not present. And somehow I cannot model this behavior in Galaxy.
A different solution would of course be to ask the author(s) of samtools to have an option available where the user can directly indicate the path to the index file.
regards, Michiel
PS: I've searched the mailing list archives for this problem but did not find any matches. Apologies if I somehow missed the answer.
-- ================================================================== Michiel Van Bel, PhD Expert Bioinformatician Tel:+32 (0)9 331 36 95 fax:+32 (0)9 3313809 VIB Department of Plant Systems Biology, Ghent University Technologiepark 927, 9052 Gent, BELGIUM mibel@psb.vib-ugent.be http://www.psb.vib-ugent.be http://bioinformatics.psb.ugent.be ==================================================================
___________________________________________________________ Please keep all replies on the list by using "reply all" in your mail client. To manage your subscriptions to this and other Galaxy lists, please use the interface at: http://lists.bx.psu.edu/
To search Galaxy mailing lists use the unified search at: http://galaxyproject.org/search/mailinglists/
Hi Michiel, Did you finish wrapping samtools idxstats? I can't see it on the Tool Shed... If not, I may tackle this shortly. Peter On Wed, May 22, 2013 at 2:39 PM, Jeremy Goecks <jeremy.goecks@emory.edu> wrote:
Galaxy stores a BAI for each BAM internally; you can access it in a tool wrapper like this (assuming the name of your input dataset is 'input_bam':
${input_bam.metadata.bam_index}
Once you have the file path, you can set up a symbolic link to it and the tool should work fine.
Good luck, J.
On May 22, 2013, at 4:05 AM, Michiel Van Bel wrote:
Hi,
I would like to inquire whether anyone has attempted to implement the idxstats tool from samtools into Galaxy? The xml-file for idxstats is not present in the Galaxy source code, which led me to try and implement it myself. However, the main problem I face is that the idxstats tool silently relies on having an index file available (within the same directory) for the bam file you which to print the stats for. E.g. samtools idxstats PATH/test.bam searches for PATH/test.bam.bai and gives an error when this file is not present. And somehow I cannot model this behavior in Galaxy.
A different solution would of course be to ask the author(s) of samtools to have an option available where the user can directly indicate the path to the index file.
regards, Michiel
PS: I've searched the mailing list archives for this problem but did not find any matches. Apologies if I somehow missed the answer.
On Thu, Nov 7, 2013 at 4:51 PM, Peter Cock <p.j.a.cock@googlemail.com> wrote:
Hi Michiel,
Did you finish wrapping samtools idxstats? I can't see it on the Tool Shed...
If not, I may tackle this shortly.
Peter
I've implemented a 'samtools idxstats' wrapper, which seems to be working for me: https://github.com/peterjc/pico_galaxy/blob/master/tools/samtools_idxstats/s... Test Tool Shed: http://testtoolshed.g2.bx.psu.edu/view/peterjc/samtools_idxstats Main Tool Shed (pending - I want to see the overnight test results on the Test Tool Shed first): http://toolshed.g2.bx.psu.edu/view/peterjc/samtools_idxstats Regards, Peter
On Mon, Nov 11, 2013 at 5:29 PM, Peter Cock <p.j.a.cock@googlemail.com> wrote:
On Thu, Nov 7, 2013 at 4:51 PM, Peter Cock <p.j.a.cock@googlemail.com> wrote:
Hi Michiel,
Did you finish wrapping samtools idxstats? I can't see it on the Tool Shed...
If not, I may tackle this shortly.
Peter
I've implemented a 'samtools idxstats' wrapper, which seems to be working for me: https://github.com/peterjc/pico_galaxy/blob/master/tools/samtools_idxstats/s...
Test Tool Shed: http://testtoolshed.g2.bx.psu.edu/view/peterjc/samtools_idxstats
Main Tool Shed (pending - I want to see the overnight test results on the Test Tool Shed first): http://toolshed.g2.bx.psu.edu/view/peterjc/samtools_idxstats
Having sorted out the dependency management, and seen the test pass on the Test Tool Shed, this "samtools idxstats" wrapper is now live on the main Tool Shed as well: http://toolshed.g2.bx.psu.edu/view/peterjc/samtools_idxstats Peter
participants (3)
-
Jeremy Goecks
-
Michiel Van Bel
-
Peter Cock