Question: How to extract mitogenomes from these fasta files? HELP
0
gravatar for Andrea.Neobahamut
7 months ago by
Andrea.Neobahamut0 wrote:

Hello, please someone help me to solve this: I have many contigs on fasta format, already ran a BLAST to them against the own database I created Commercial Photography Commercial Photography

The next step I need to do is pulling out the mitogenomes, I heard of two options, grep and using NOVOPLASTY, but I cant find a tutorial that can explain how to extract this from a fasta format I'd appreciate your help, thank you

ADD COMMENTlink modified 7 months ago by h.mon27k • written 7 months ago by Andrea.Neobahamut0

Can you post example contents of the files *.namelist?

ADD REPLYlink written 7 months ago by vkkodali1.1k
1
gravatar for h.mon
7 months ago by
h.mon27k
Brazil
h.mon27k wrote:

Please don't:

  • write HELP in capitals in your title - it isn't good manners and won't help you get an answer.
  • post large screenshots of text (such as commands, file names and text file contents). It is better to copy and paste those as text inside your question, preferably using the formatting buttons to structure your post.

Please do:

  • explain in detail your problem. For example, what is the "own database" you created? Why do you have several "own databases"? Do you have one contig per file, and many fasta files, or each fasta contains multiple contigs? What is the contents of the namelist files? Do you intend to pull the contigs from the database or from the fastas with contigs?

Some general comments on your code:

1) don't use

for i in `ls ANT198n.fasta*`

It is error-prone, use instead:

for i in ANT198n.fasta*

2) As far as I can tell from your screenshots, ls ANT198n.fasta* will return ANT198n.fasta, so you are using a for loop to loop over just one file - that is, the for loop is unnecessary.

Finally, assuming you want to pull out the hits from the fasta files, you can use samtools:

samtools faidx ANT198n.fasta
samtools faidx ANT198n.fasta $(cat ANT198n.fasta,namelist) > csulcatus.mt.fasta
ADD COMMENTlink modified 7 months ago • written 7 months ago by h.mon27k

Thank you SO MUCH, thanks for the advices, I just type that command on samtools after I ran BLAST on my contigs, it works!!!!

ADD REPLYlink written 6 months ago by Andrea.Neobahamut0
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1139 users visited in the last hour