Hi Alan,
Thank you again. I did not give a try by using
dictionary power. It works now.
Thanks again for tip.
-srini.
dida = {}
for m in nbat:
cols = m.split('\t')
old = cols[0]
dida.setdefault(old,[]).append(cols[1])
lista = ndat.split('\n')
result = []
for i in li
> One of the proble is that, Contig27915_RC is seen
> associated with many XM entries in nbat. However,
> with the above script I could replace only once in
> xta. I could not print Contig27915_RC with many XM_
> guys in nbat. How can this be done.
>
> Finally, this whole process seems to be more
Sorry for the very long email. and I my brain is dead
to create some related generic snippet. Thus, I shrunk
the string and lists into as short as I could.
apologies again.
srini
--- Srinivas Iyyer <[EMAIL PROTECTED]> wrote:
> Dear Tutors,
> I have a huge string and 2 lists. List A consists
>
Dear Tutors,
I have a huge string and 2 lists. List A consists of
tabed elements, where first tab represents entry
somewhere in string(ndat).
ndat has 'Contig27915_RC' and List A [nbat]has
'Contig27915_RC\tXM_945977'. List B [nmlist]has
elements, for instance ['XM_945977\tNM_152513']. Now
my tas