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

              • kinpict.com
                Reply to 16S/ITS Profiling vs. Shotgun Metagenomics: What Changes in Your Workflow?
                by kinpict.com
                The part about this topic feels surprisingly grounded, and the details on the page is the bit that made me slow down. I’d keep <a href="https://kinpict.com/">ai family photo generator</a> bookmarked for later.
                Today, 06:37 PM
              • SEQadmin2
                16S/ITS Profiling vs. Shotgun Metagenomics: What Changes in Your Workflow?
                by SEQadmin2





                NGS has revolutionized clinical microbiology by offering new ways to identify and surveil pathogens without prior knowledge of the target. One popular approach is 16S rRNA and ITS amplicon sequencing, which targets specific microbial markers. But studies are increasingly incorporating shotgun metagenomics, a technique that sequences all DNA from a sample without targeting specific microbial markers. This approach allows more detailed taxonomic classification,...
                10-30-2026, 06:46 AM

              ad_right_rmr

              Collapse

              News

              Collapse

              Topics Statistics Last Post
              Started by SEQadmin2, 11-12-2026, 07:59 AM
              0 responses
              28 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, 11-05-2026, 09:25 AM
              0 responses
              35 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, 11-03-2026, 11:54 AM
              2 responses
              56 views
              0 reactions
              Last Post kinpict.com  
              Started by SEQadmin2, 10-28-2026, 09:57 AM
              0 responses
              175 views
              0 reactions
              Last Post SEQadmin2  
              Working...