To convert SAM to BAM, we use the samtools view command. ![]() However, it is consequently very difficult for humans to read. The binary format is much easier for computer programs to work with. To do anything meaningful with alignment data from BWA or other aligners (which produce text-based SAM output), we need to first convert the SAM to its binary counterpart, BAM format. Samtools depth Converting SAM to BAM with samtools “view” ![]() curl > Īs you can see, there are multiple “subcommands” and for samtools to work you must tell it which subcommand you want to use. cd samtools-demoĭownload the example gzipped SAM file I have provided. you may already have a src directoryĬreate a new directory from your home directory called “samtools-demo”. ![]() Our goal is to work through examples that demonstrate how to explore, process and manipulate SAM and BAM files with the samtools software package.įor future reference, use the samtools documentation.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |