[BiO BB] A question about replacing a substring using Bioperl
mayagao at gmail.com
Fri Jul 15 13:32:32 EDT 2005
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
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!
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the BBB