This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How to extract multiple header from fasta file

Pls help, anyone know how to extract multiple header from a fasta file using perl?

sequence

Dear fongsiongshawn, Hi

Is there any help here for you?

~ Best

It's good that you've to this forum to ask, but in many cases, try upgrade your googling skill. Your exact question has been answered in the thread mentioned by Farbod

2 answers

If you want all of the header lines, you can just use linux:

grep  '^>'  sequences.fasta   >  headers.txt

Not perl, but maybe a much simpler way: Create a blast db of your fasta file and use blastdbcmd.

Explained here

Log in to answer this question.