I have the following code:
$qSeq = "ATTA";
$suchmuster = array("/A/","/T/","/G/","/C/","/U/");
$ersetzungen = array("T","A","C","G","A");
$qSeq = preg_replace($suchmuster, $ersetzungen, $qSeq);
echo $qSeq;
My aim is that i.e. ATTA becomes TAAT, this logic works fine in Ruby, but PHP will kinda produce AAAA. Any idea how this might work with PHP ?
Tnx!