convertion from SAM to BAM
2
0
Entering edit mode
João Moura ▴ 160
@joao-moura-4505
Last seen 9.6 years ago
Hello, Do you know any way of convertin SAM to BAM using bioconductor? Thanks in advance, -- João Moura [[alternative HTML version deleted]]
• 4.0k views
ADD COMMENT
0
Entering edit mode
@sean-davis-490
Last seen 12 weeks ago
United States
On Tue, Apr 26, 2011 at 8:52 AM, Jo?o Moura <palerma at="" gmail.com=""> wrote: > Hello, > > Do you know any way of convertin SAM to BAM using bioconductor? Hi, Joao. Untested: system(sprintf("samtools view -bS %s > %s",samfilename,bamfilename)) Sean
ADD COMMENT
0
Entering edit mode
Thank you Sean and Paul, Actually I was looking for something to using in R without calling samtools. Thanks, On Tue, Apr 26, 2011 at 3:13 PM, Sean Davis <sdavis2@mail.nih.gov> wrote: > On Tue, Apr 26, 2011 at 8:52 AM, João Moura <palerma@gmail.com> wrote: > > Hello, > > > > Do you know any way of convertin SAM to BAM using bioconductor? > > Hi, Joao. > > Untested: > > system(sprintf("samtools view -bS %s > %s",samfilename,bamfilename)) > > Sean > -- João Moura [[alternative HTML version deleted]]
ADD REPLY
0
Entering edit mode
Hi, On Tue, Apr 26, 2011 at 9:17 AM, Jo?o Moura <palerma at="" gmail.com=""> wrote: > Thank you Sean and Paul, > > Actually I was looking for something to using in R without calling samtools. To convert sam -> bam without leaving the comfort of your aRm chair, try: R> library(Rsamtools) R> ?asBam Scan the docs to see how asBam works. I'm not sure when that was added. If you don't see it in your install, maybe you need to be running R-2.13 and bioc 2.8 -steve -- Steve Lianoglou Graduate Student: Computational Systems Biology ?| Memorial Sloan-Kettering Cancer Center ?| Weill Medical College of Cornell University Contact Info: http://cbio.mskcc.org/~lianos/contact
ADD REPLY
0
Entering edit mode
On 04/26/2011 06:26 AM, Steve Lianoglou wrote: > Hi, > > On Tue, Apr 26, 2011 at 9:17 AM, Jo?o Moura<palerma at="" gmail.com=""> wrote: >> Thank you Sean and Paul, >> >> Actually I was looking for something to using in R without calling samtools. > > To convert sam -> bam without leaving the comfort of your aRm chair, try: > > R> library(Rsamtools) > R> ?asBam > > Scan the docs to see how asBam works. > > I'm not sure when that was added. If you don't see it in your install, > maybe you need to be running R-2.13 and bioc 2.8 Rsamtools tries to keep it's NEWS file up-to-date, so > news(package="Rsamtoools") Changes in version 1.4.0: NEW FEATURES ... o asBam converts SAM files to (indexed) BAM files Martin > > -steve > -- Computational Biology Fred Hutchinson Cancer Research Center 1100 Fairview Ave. N. PO Box 19024 Seattle, WA 98109 Location: M1-B861 Telephone: 206 667-2793
ADD REPLY
0
Entering edit mode
Hi, That's great, thank you! On Tue, Apr 26, 2011 at 3:26 PM, Steve Lianoglou < mailinglist.honeypot@gmail.com> wrote: > Hi, > > On Tue, Apr 26, 2011 at 9:17 AM, João Moura <palerma@gmail.com> wrote: > > Thank you Sean and Paul, > > > > Actually I was looking for something to using in R without calling > samtools. > > To convert sam -> bam without leaving the comfort of your aRm chair, try: > > R> library(Rsamtools) > R> ?asBam > > Scan the docs to see how asBam works. > > I'm not sure when that was added. If you don't see it in your install, > maybe you need to be running R-2.13 and bioc 2.8 > > -steve > > -- > Steve Lianoglou > Graduate Student: Computational Systems Biology > | Memorial Sloan-Kettering Cancer Center > | Weill Medical College of Cornell University > Contact Info: http://cbio.mskcc.org/~lianos/contact > -- João Moura [[alternative HTML version deleted]]
ADD REPLY
0
Entering edit mode
Paul Geeleher ★ 1.3k
@paul-geeleher-2679
Last seen 9.6 years ago
Not sure if you can do it from within Bioconductor, but the command line tool samtools will let you do it. If you really need to do it from within R I suppose you could call samtools from R. Paul. On Tue, Apr 26, 2011 at 1:52 PM, Jo?o Moura <palerma at="" gmail.com=""> wrote: > Hello, > > Do you know any way of convertin SAM to BAM using bioconductor? > > Thanks in advance, > > -- > Jo?o Moura > > ? ? ? ?[[alternative HTML version deleted]] > > > _______________________________________________ > Bioconductor mailing list > Bioconductor at r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor > -- Paul Geeleher (PhD Student) School of Mathematics, Statistics and Applied Mathematics National University of Ireland Galway Ireland -- www.bioinformaticstutorials.com
ADD COMMENT

Login before adding your answer.

Traffic: 807 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6