I have a folder with multifasta files and I would like to extract the headers from each one of them, I've used the following command in shell
grep -e ">" *.fasta > prueba_nc.txt
the output looks like it
Adenoviridae_genomas.fasta:>AC_000001 [AC_000001] Ovine adenovirus A, complete genome.
Adenoviridae_genomas.fasta:>AC_000002 [AC_000002] Bovine adenovirus B, complete genome.
Adenoviridae_genomas.fasta:>AC_000003 [AC_000003] Canine adenovirus 1, complete genome.
...
and I would like to extract only the fragment after the ">"
I added code markup to your post for increased readability. You can do this by selecting the text and clicking the 101010 button. When you compose or edit a post that button is in your toolbar, see image below:
Did you upvote just my answer? Please validate the other answers and provide feedback, if at all possible. Muchas gracias.
You are absolutely right Kevin, I have upvoted it ;-)
Okay, thanks. Did you look at the other solutions by the others?
Hi Ulises, although this can be easily achieved as other people has already explained, if you are working with FASTA files you may be interested in SEDA (http://www.sing-group.org/seda/). Please, take a look and feel free to contact us if you need some assistance using it. Regards.