Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • bam to sam coversion and flagstat

    Hi Everybody,

    I converted the Tophat result accepted_hits.bam to .sam using
    samtools view accepted_hits.bam > accepted_hits.sam

    and now my sam file looks like
    SOLEXA1_0001:7:53:1361:1750#0 163 pcu_contig_1 78 255 84M = 139 0 GTTCGCGTATTTTGGTCGAAATGCTAAAAGCTCAACAGCCTTTGCGATACATGCGTCGTCACTAGGGTACAATGCCAGCCATGCHHHHHIHHHHDHHHHGHHHHHHHGHHHHHHHHGHHEHHHGHHFHDHGHHHHHHGHBHHGHHHHHHHHDHHHDGHBHGHGHHEFG NM:i:0 NH:i:1
    SOLEXA1_0001:7:26:430:480#0 99 pcu_contig_1 117 255 84M = 195 0 CTTTGCGATACATGCGTCGTCACTAGGGTACAATGCCAGCCATGCTATTGAGCAAGTTAACAGTTGACATGAAGCTAGATCGCGHHHHHHHHHHHHHHHHHHHHHHHHHHHHGHHHHHHHDHHFHHHHEHHHHHHHHHFHIHHGEFHHHHIIGHHFIHAGH?GGBGFB NM:i:0 NH:i:1
    Now when i try to run flagstat, it shows following;

    [bam_header_read] EOF marker is absent.
    [bam_flagstat_core] Truncated file? Continue anyway.

    and the flaststat is

    0 in total
    0 QC failure
    0 duplicates
    0 mapped (nan%)
    0 paired in sequencing
    0 read1
    0 read2
    0 properly paired (nan%)
    0 with itself and mate mapped
    0 singletons (nan%)
    0 with mate mapped to a different chr
    0 with mate mapped to a different chr (mapQ>=5)

    I do not know what i am doing wrong. It could be the way i converted my bam file to sam or something else.

  • #2
    Usage: samtools flagstat <in.bam>

    flagstat needs BAM as input. why do you want to convert to SAM in the first place?

    Comment


    • #3
      Try GUI tool SAMMate. It allows one to convert SAM to BAM and vice versa.

      Comment

      Latest Articles

      Collapse

      • seqadmin
        Essential Discoveries and Tools in Epitranscriptomics
        by seqadmin


        The field of epigenetics has traditionally concentrated more on DNA and how changes like methylation and phosphorylation of histones impact gene expression and regulation. However, our increased understanding of RNA modifications and their importance in cellular processes has led to a rise in epitranscriptomics research. “Epitranscriptomics brings together the concepts of epigenetics and gene expression,” explained Adrien Leger, PhD, Principal Research Scientist on Modified Bases...
        Yesterday, 07:01 AM
      • seqadmin
        Current Approaches to Protein Sequencing
        by seqadmin


        Proteins are often described as the workhorses of the cell, and identifying their sequences is key to understanding their role in biological processes and disease. Currently, the most common technique used to determine protein sequences is mass spectrometry. While still a valuable tool, mass spectrometry faces several limitations and requires a highly experienced scientist familiar with the equipment to operate it. Additionally, other proteomic methods, like affinity assays, are constrained...
        04-04-2024, 04:25 PM

      ad_right_rmr

      Collapse

      News

      Collapse

      Topics Statistics Last Post
      Started by seqadmin, 04-11-2024, 12:08 PM
      0 responses
      39 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-10-2024, 10:19 PM
      0 responses
      41 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-10-2024, 09:21 AM
      0 responses
      35 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-04-2024, 09:00 AM
      0 responses
      55 views
      0 likes
      Last Post seqadmin  
      Working...
      X