Seqanswers Leaderboard Ad

Collapse

Announcement

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

  • BAM header file error

    I ran the following the command to extract bam file for specific chromosomal locus.

    samtools view -h accepted_hits.bam "EQ963475:334376-335722">AFLA_105440.bam

    The result of command was generated with header file
    ######first few lines output file######
    @HD VN:1.0 SO:coordinate
    @SQ SN:EQ963472 LN:4469204
    @SQ SN:EQ963473 LN:4149026
    @SQ SN:EQ963474 LN:2713190
    @SQ SN:EQ963475 LN:2658400
    @SQ SN:EQ963476 LN:2555871
    @SQ SN:EQ963477 LN:2388123
    @SQ SN:EQ963478 LN:2337902

    When I ran the below command for conversion of bam to fastq

    samtools bam2fq AFLA_105440.bam >AFLA_105440.fq

    it showing error like this:
    [bam_header_read] EOF marker is absent. The input is probably truncated.
    [bam_header_read] invalid BAM binary header (this is not a BAM file).

    My ultimate objective is to get fasta file from bam. Thats y I am converting bam file into fastq..... So any one please what is /are tools available for this converion

  • #2
    Hi Muthukumar,

    with your first command, you generated a SAM file. In order to use samtools bam2fq, you need a bam file:
    Code:
    samtools view -h[B]b[/B] accepted_hits.bam "EQ963475:334376-335722">AFLA_105440.bam
    That should do the job.

    Cheers,
    Michael

    Comment


    • #3
      Thank you very much its working now.
      Originally posted by Michael.Ante View Post
      Hi Muthukumar,

      with your first command, you generated a SAM file. In order to use samtools bam2fq, you need a bam file:
      Code:
      samtools view -h[B]b[/B] accepted_hits.bam "EQ963475:334376-335722">AFLA_105440.bam
      That should do the job.

      Cheers,
      Michael

      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...
        04-22-2024, 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
      59 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-10-2024, 10:19 PM
      0 responses
      57 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-10-2024, 09:21 AM
      0 responses
      51 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