Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • flacchy
    Member
    • Apr 2013
    • 33

    extract reads from Blast output

    Hi...

    I hope that someone can help me out with this one.

    I ran blast against a db I created (specifically is from an organism I want to remove from my reads). So I ran the blast analyses and now I would like to extract all the reads and sequence that didn't have hits.

    is this possible and how can I extract the reads I want from the blast output?

    Thanks

    F.
  • okorist
    Junior Member
    • Jul 2013
    • 3

    #2
    I suggest that you add the option "-outfmt 7" when running blast. This would make the result look like this:

    # Fields: query id, subject id, % identity, alignment length, mismatches, gap opens, q. start, q. end, s. start, s. end, evalue, bit score
    5 # 157 hits found
    6 sp|Q91G65|032R_IIV6 gi|15078745|ref|NP_149495.1| 100.00 100 0 0 1 100 1 100 6e-64 198
    7 sp|Q91G65|032R_IIV6 gi|291396174|ref|XP_002714758.1| 36.56 93 58 1 9 100 60 152 4e-15 74.7
    8 sp|Q91G65|032R_IIV6 gi|296198107|ref|XP_002746567.1| 35.48 93 59 1 9 100 60 152 5e-15 74.3
    9 sp|Q91G65|032R_IIV6 gi|116004445|ref|NP_001070581.1| 36.56 93 58 1 9 100 60 152 8e-15 73.9
    10 sp|Q91G65|032R_IIV6 gi|126309825|ref|XP_001370260.1| 36.56 93 58 1 9 100 60 152 1e-14 73.6

    Then it would be easier to extract the reads from the output.

    Comment

    • flacchy
      Member
      • Apr 2013
      • 33

      #3
      I used a script to obtain the same output ... the issue is extract them...

      Comment

      • rhinoceros
        Senior Member
        • Apr 2013
        • 372

        #4
        Originally posted by flacchy View Post
        I used a script to obtain the same output ... the issue is extract them...
        blastdbcmd, read the manual..
        savetherhino.org

        Comment

        • flacchy
          Member
          • Apr 2013
          • 33

          #5
          I've read the manual but I found more useful use the script ncbi_parse.pl because I needed the description of the organism before and the tab output don't gave that infromation (I saw also in some blog other people having the same issue) I was only wondering if there was a way to extract the reads and sequence of the no hits from the output...

          Comment

          • rhinoceros
            Senior Member
            • Apr 2013
            • 372

            #6
            Originally posted by flacchy View Post
            I've read the manual but I found more useful use the script ncbi_parse.pl because I needed the description of the organism before and the tab output don't gave that infromation (I saw also in some blog other people having the same issue) I was only wondering if there was a way to extract the reads and sequence of the no hits from the output...
            With blast 2.2.28+ you can have organism name in the output given you have setup taxdb properly and use e.g. -outfmt '6 std sscinames'..
            savetherhino.org

            Comment

            • GenoMax
              Senior Member
              • Feb 2008
              • 7142

              #7
              flacchy wants to extract reads that did not have a blast hit in results. Not sure if blastdbcmd allows that.

              Comment

              • rhinoceros
                Senior Member
                • Apr 2013
                • 372

                #8
                Originally posted by GenoMax View Post
                flacchy wants to extract reads that did not have a blast hit in results. Not sure if blastdbcmd allows that.
                Ah yeah, my bad. So for tsv/csv output:

                cut -f 1 (optional -d ',' for csv) yourResultFile | sort -u > seqIdsYouWantToRemove.txt. Then ideas for that from for example here..
                Last edited by rhinoceros; 07-25-2013, 06:28 AM.
                savetherhino.org

                Comment

                • yzzhang
                  Member
                  • Jan 2013
                  • 67

                  #9
                  once you get the reads list you want to remove, you can use comm command to get left reads names wanted, and then extract them very easily. fastqselect.tcl from mira software works very well

                  Comment

                  Latest Articles

                  Collapse

                  • SEQadmin2
                    Cancer Drug Resistance: The Lingering Barrier to Rising Survival
                    by SEQadmin2



                    Cancer survival rates have significantly increased in the last few decades in the United States, reaching a combined 70% 5-year survival rate by 2021. Behind this number, there are years of research to find new therapies, drug targets, and early detection methods. But there is one core challenge that keeps slowing down these advances, and it’s about drug resistance.

                    There is no single reason why many patients don’t respond to treatment as expected. Cancer is...
                    Yesterday, 05:17 AM
                  • GATTACAT
                    Reply to Nine Things a Sample Prep Scientist Thinks About Before Sequencing
                    by GATTACAT
                    Love this - good data definitely starts from good input, and poor input can only give relatively poor data. I particularly like the mention of Nanodrop/absorbance based methods for quantification. It's such a toss up if you'll get an accurate reading or what amounts to a randomly generated number, and a lot of library/sequencing related issues can be traced back to poor quant.
                    07-01-2026, 11:43 AM
                  • SEQadmin2
                    Nine Things a Sample Prep Scientist Thinks About Before Sequencing
                    by SEQadmin2


                    I’m not a sequencing expert. I’m a purification scientist who uses NGS to evaluate workflows my group develops. With this perspective, we think about the sample first and the NGS workflow second. The sequencer is an exceptionally honest reporter, but it can only report on what you give it, so whether you get clean, interpretable data from an NGS workflow is largely determined before you begin.

                    Here are nine questions we think about, in roughly the order they matter, before...
                    06-18-2026, 07:11 AM

                  ad_right_rmr

                  Collapse

                  News

                  Collapse

                  Topics Statistics Last Post
                  Started by SEQadmin2, Yesterday, 10:08 AM
                  0 responses
                  6 views
                  0 reactions
                  Last Post SEQadmin2  
                  Started by SEQadmin2, 07-07-2026, 11:05 AM
                  0 responses
                  8 views
                  0 reactions
                  Last Post SEQadmin2  
                  Started by SEQadmin2, 07-02-2026, 11:08 AM
                  0 responses
                  31 views
                  0 reactions
                  Last Post SEQadmin2  
                  Started by SEQadmin2, 06-30-2026, 05:37 AM
                  0 responses
                  29 views
                  0 reactions
                  Last Post SEQadmin2  
                  Working...