[Bioperl-l] A question about replacing a substring using Bioperl

Gao Zhang mayagao at gmail.com
Fri Jul 15 13:32:32 EDT 2005

Dear all,

I have a txt file which stores 20 short DNA sequences and the length of each 
is 8, let's 
call it A. Meanwhile, I have another txt file which owns 100 long DNA 
sequences and the length of each is
200, let's call it B. 

Then, I want to replace a substring of each sequence in B with each one in 
The replacement starting site could be specified as you want(such as
starting at position 1 for the first sequence in B, 10th for the 2nd 
sequence in
B, 20th for the 3rd, until 190th for the 20th in B ) or picked
by the program randomly. I am pretty sure 
substr(string,index,length,replacement string) can finish a part
of this work. 

But I have limited experience of using Perl to manipulate two files. Can 
give me some suggestions?

Thank you very much and look forward to your reply!

Best Regards,

More information about the Bioperl-l mailing list