Off topic:Rename fasta file header with name available in the text file
0
0
Entering edit mode
8.5 years ago

Hi, I am trying to change the fasta header with a given list. I have a fasta file which looks like-

>P1212_1 M04I6TDD
GACGAACGCTGGCGGCGTGCTTAACACATGCAAGTCGAACGAGAGGAGAAGGAAGCTTGCCTCTTTCAAATCT
>P1213_2 M04JTWVX 
GATAAACGCTGGCGGCGCACATAAGACATGCAAGTCGAACGAACTTAACCATTAGTTTACTATTGGAGCGGTTAGTG

And I have another file in text format (tab delimited), which looks like -

P1212  SHA1111
P1213  SHA2222
P1214  SHA3333

I want to rename the header of above fasta file according to corresponding name, the output file looks like-

>SHA1111_1 M04I6TDD 
GACGAACGCTGGCGGCGTGCTTAACACATGCAAGTCGAACGAGAGGAGAAGGAAGCTTGCCTCTTTCAAATCT
>SHA2222_2 M04JTWVX 
GATAAACGCTGGCGGCGCACATAAGACATGCAAGTCGAACGAACTTAACCATTAGTTTACTATTGGAGCGGTTAGTG

I am trying to use scripts mentioned here Renaming fasta headers according to a matching name list , but the output file is not correct. I'm so grateful for helping. Regards.

fasta • 3.9k views
ADD COMMENT
This thread is not open. No new answers may be added
Traffic: 2041 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6