Hello ..I am a bioinformatist ..I have a question on Perl String Matching and Replacemnet ..( I tried doing this but I am unable to get teh desired result...I appreciate your time spent ...thanks)
I have an XML file in which the element
<Biosequence_ref > occours multiple times...
for example ...
<BioSequence_ref identifier="Affymetrix.com
:Probe:HG-
U133_Plus_
2.200607_s
_at.698.59
7"/>
The only variable in the diffrent elements is that the last part after HG-UQ33_Plus_2 ..i.e
(200607_s_at.698.597) changes ...
i.e another Element can be
<BioSequence_ref identifier="Affymetrix.com
:Probe:HG-
U133_Plus_
30007_s_at
.729.598"/
>
I need to make a string replacement ....bascially
1.Whenever I see a Biosequence_ref element with an Identifier that has the word "Probe" in it
(There may be other Bioisequence_ref identifiers without the word Probe ..I should not change these)
2.I need to change the element into
<BioSequence identifier="Affymetrix.com
:Probe:HG-
U133_Plus_
2.200607_s
_at.698.59
7 sequence="DUMMY"/">
(The only addition are
1. BioSequence_ref changes to Biosequence
2,New Element sequence="DUMMY" is added which is always constant.
Thanks for your time
Start Free Trial