Entering edit mode
3.8 years ago
jbt38
•
0
I have a MSA (fasta format) with hundreds of sequences , and the descriptions are this format:
>gi|AY015275.1|taxonid|154401|organism|Leuenbergeria guamacho|seqid|AY015275.1|description|Pereskia guamacho tRNA-Lys (trnK) gene partial sequence; and maturase K (matK) gene complete cds; chloroplast genes for chloroplast products
How can I change the description of each entry to look like this?
>Leuenbergeria_guamacho
Edited to add an underscore between genus and species.
Assuming that scientific name is always sandwiched between organism and seqid:
with sed: