Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • yaximik
    Senior Member
    • Apr 2011
    • 199

    #1

    removing N inserts

    I am trying to build a comprehensive database of prokaryotic (bacteria and archea) and fungal genomes to be used for screening ancient DNA reads for contamination. What I found unfortunately that many of genomes in NCBI or EMBL databases have a lot of poly-N inserts, which obviously need to be eliminated. This can be done either by removing inserts from each FASTA record, which may be difficult, or by splitting records at poly-N inserts and trimming Ns from the ends. Is there a tool/sctipt to do this? Alternatively, I may have to abandon genomes and just concatenate GenBank relevant records, but I first will have to extract FASTA from them. Any advice?
  • swbarnes2
    Senior Member
    • May 2008
    • 910

    #2
    It's not obvious to me that they have to be taken out. Reads just won't align there, that's all.

    You could use sed to get rid of all the N's, or write a script in something to trim out sequences of Ns that are more than a certain length.

    Comment

    • yaximik
      Senior Member
      • Apr 2011
      • 199

      #3
      Well, dowloaded data files need to be preprocessed by BWA-SW to make databases for local install of DeconSeq, and the author removed Ns by splitting, as BWA-SW replaces Ns with either of A, G, C, T at random (citing the paper). But it does not say in the paper how this was done...

      Comment

      • jimmybee
        Senior Member
        • Sep 2010
        • 119

        #4
        Why do you need to remove the poly-N regions? These are gap regions that could be useful

        Comment

        • maasha
          Senior Member
          • Apr 2009
          • 153

          #5
          I am also not convinced that you should remove N's, but if you must, you can with Biopieces (www.biopieces.org):

          Code:
          read_fasta -i in.fna | transliterate_seq -d 'nN' | write_fasta -o out.fna -x

          Comment

          • yaximik
            Senior Member
            • Apr 2011
            • 199

            #6
            Wow, i did not think biopieces can do this. Gotta try!

            Comment

            • maasha
              Senior Member
              • Apr 2009
              • 153

              #7
              @yaximik

              For more finegrained control you can use substitute_vals to remove blocks of N's longer than 25:

              Code:
              read_fasta -i in.fna | substitute_vals -k SEQ -s 'N{25,}' -r '' -ig | write_fasta -o out.fna -x

              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, Yesterday, 11:13 AM
              0 responses
              16 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, Yesterday, 10:48 AM
              0 responses
              17 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, 10-15-2026, 10:52 AM
              0 responses
              35 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, 10-14-2026, 05:39 AM
              0 responses
              42 views
              0 reactions
              Last Post SEQadmin2  
              Working...