Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dbob
    Junior Member
    • Feb 2016
    • 8

    #1

    How to perform alignment between BWA's sam file and contigs.fasta assembly files

    I performed de novo genome assembly on a bacteria sample (two files: reads.1.fq and reads.2.fq), got resulting the "contigs.fasta" file, used BWA to map the two initial fq read files to "contigs.fasta". Now I have the resulting SAM file from BWA.

    How can I perform alignment between those two files and compare my "contigs.fasta" file with the SAM file resulting from BWA?
  • GenoMax
    Senior Member
    • Feb 2008
    • 7142

    #2
    You have already performed an alignment with your original data files to the contigs.fasta, which resulted in the SAM file. You would want to convert this SAM file to BAM (binary representation) using samtools, sort it and then use a viewer such as Integrated Genome Viewer (IGV) to view the alignments.

    Comment

    • dbob
      Junior Member
      • Feb 2016
      • 8

      #3
      I used Tablet to view the alignments. However, that is not exactly what I am looking for, what I am trying to achieve here is that; the bacteria comes from soil, and in the process two bacteria genomes were extracted, I have the reads (shotgun sequencing) from only one bacteria, I performed de novo assembly to assemble the genome of that bacteria, then my task was to use the assembled genome of that bacteria to assemble the genome of the second bacteria. So I used BWA to achieve that. Now I am assuming that that SAM file is the genome of the second bacteria. Now I want to align the first bacteria against the second bacteria.

      Am I way off the road?

      By the way, the data is simulated. Bacteria one is simulated with Matlab, and bacteria two is basically bacteria one with some SNPs and deletions and insertions introduced by Matlab.

      Comment

      • GenoMax
        Senior Member
        • Feb 2008
        • 7142

        #4
        If bacteria two is essentially like bacteria one (with some SNP's, deletions etc) then you are not going to be able to separate the two "genomes" (unless the reads were tagged to identify the two samples before they were sequenced/simulated).

        What exactly are you trying to do? Are these bacteria supposed to be from two strains or two separate species or two separate genera. That order indicates increasing differences that would be easier to resolve by sequencing. But just between the strains it is going to be difficult to separate the two genomes.

        BTW: bwa is an alignment program. An assembly program example would be SPAdes/velvet for bacterial genomes. Unless you are referring to using bwa to do a reference based alignment and then get a consensus from that alignment "assembly" of second genome.
        Last edited by GenoMax; 02-09-2016, 03:59 PM.

        Comment

        • dbob
          Junior Member
          • Feb 2016
          • 8

          #5
          I am not quite sure myself of the details, since this is only a "genome assembly" practice with several sub-tasks. These two bacteria are both from one soil sample.

          I did the genome assembly for the first bacteria using Velvet, SPAdes, ABySS, and Minia.

          Yes that is probably what I should do: "[...] get a consensus from that alignment "assembly" of second genome."

          In short what I have done so far is:

          (i) Performed genome assembly using the aforementioned assemblers
          (ii) Used MUMmer to compare the results of different assemblers
          (iii) Analysed the assembly results using QUAST, chose the one that was best in terms of quality
          (iv) used that contigs.fasta file and the original reads and BWA in the following way in hope of getting the second bacteria:

          bwa index contigs.fa
          bwa aln contigs.fa reads.1.fq > align_1.sai
          bwa aln contigs.fa reads.2.fq > align_2.sai
          bwa sampe contigs.fa align_1.sai align_2.sai reads.1.fq reads.2.fq > align_bwa.sam


          Details of the task if needed:

          Comment

          • GenoMax
            Senior Member
            • Feb 2008
            • 7142

            #6
            "Closely related bacteria" is vague and subject to interpretation. The farther you are allowed to go the better your chances will be of "separating" the genomes.

            You actually should be thinking about the reads that don't map because they would potentially represent the "other" bacterium. You would want to separate and then assemble those. This task appears to be not very well defined.
            Last edited by GenoMax; 02-09-2016, 05:08 PM.

            Comment

            Latest Articles

            Collapse

            • SEQadmin2
              Multiomic Liquid Biopsy: What DNA/RNA Panels Reveal That DNA Alone Can’t
              by SEQadmin2



              Tumors contain complex mixtures of cell populations that evolve in response to treatment and host-specific factors. Tissue biopsies provide only static snapshots of a tumor’s state. But what if we could follow that evolution over time using a minimally invasive technique?

              Liquid biopsies can detect tumor-derived material circulating in the bloodstream, providing a way to study treatment response, detect emerging resistance, and discover new biomarkers. Circulating
              ...
              10-14-2026, 09:55 AM
            • SEQadmin2
              New Genomics Technologies Take Aim at Long-Standing Limits
              by SEQadmin2


              Researchers using sequencing and genomics tools often have to make trade-offs. They can choose between speed or scale, short reads or long-range information, or targeted panels or a view of the whole transcriptome. New technologies that have been released this year are built to address those tough choices.

              We asked six companies the same four questions to learn about their latest products. The new technologies bring a lot to the table, including rethinking sequencing
              ...
              09-28-2026, 10:25 AM

            ad_right_rmr

            Collapse

            News

            Collapse

            Topics Statistics Last Post
            Started by SEQadmin2, 10-22-2026, 11:13 AM
            0 responses
            32 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-22-2026, 10:48 AM
            0 responses
            23 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-15-2026, 10:52 AM
            0 responses
            40 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-14-2026, 05:39 AM
            0 responses
            45 views
            0 reactions
            Last Post SEQadmin2  
            Working...