one for which N,CA and C all are missing,
I tried in this way:
import re
f = open('chem.txt')
for line in f:
if re.search('C = ',''):
print line
but i am not getting the desired output.
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
I tried to print those lines having C value missing by:
import re
expr = re.compile("C = None")
f = open("/home/amrita/helix.dat")
for line in f:
if expr.search(line):
print line
but it is not giving any value.
>
> Hi,
>
> I have two large files:
>
ain__":
... a = open("/home/amrita/alachems/chem100.txt")
... c = open("/home/amrita/secstr/secstr100.txt")
...
>>> def source(stream):
... return (line.strip() for line in stream)
...
...
>>> def merge(sources):
... for m in merge([source(a),
les together using command...
>>
>> from itertools import izip
>> from os.path import exists
>>
>> def parafiles(*files):
>> vec = (open(f) for f in files if exists(f))
>> data = izip(*vec)
>> [f.close() for f in vec]
>> return
I tried to join these two files together using command...
from itertools import izip
from os.path import exists
def parafiles(*files):
vec = (open(f) for f in files if exists(f))
data = izip(*vec)
[f.close() for f in vec]
return data
for data in parafiles('/home/a
ALA H = 8.78 N = 120.16 CA = 55.84 HA = 4.14 C = 179.93 ChainA:
ALA23 -59.148095 -46.540043
ChainA:
ALA33 -65.459303 -43.269718
Thanks,
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
http://mail.python.org
mino acid(given by second
column)then amino acid here it is ALA and then the corresponding value of
C, CA and CB from 5th colum for each position of ALA.
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
http://mail.python.org/mailman/listinfo/python-list
that i will make another file in which first it will write
the position of ALA lets say 8 then its name ALA and then the chemical
shift value for only three atoms C,CA and CB.
Means it will be someting like:
8 ALA C = 179.39 CA = 54.67 CB = 18.85
I tried but its not coming.
Thanks,
Amrita
t;PHE|ASP",line):
>> print line
>>
>
> The readlines() is unnecessary, and if your file is at all long you'd
> be better off precompiling the regular expression.
>
> import re
>
> expr = re.compile("PHE|ASP")
> with open("filename") as f:
> for line in f:
> if expr.search(line):
> print line
>
> --
> Rhodri James *-* Wildebeest Herder to the Masses
> --
> http://mail.python.org/mailman/listinfo/python-list
>
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
http://mail.python.org/mailman/listinfo/python-list
the command for that.
Thanks,
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
http://mail.python.org/mailman/listinfo/python-list
Dear all,
I want to know if i want to copy one paragraph from one text file to
another then what command i have to use in python.Looking forwaard for
soon reply.
Thanks,
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
http://mail.python.org/mailman/listinfo/python-list
Dear all,
Can anyone tell me that suppose i want to copy few lines from one text
file to another then how can i do that.Looking forward for soon reply.
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
http://mail.python.org/mailman/listinfo/python-list
Hi,
I want to know that whether using python programming is it possible to
extract chemical shift information about some amino acids of some protein
from BMRB(BioMagResBank) or Ref-DB(referenced databank) or not.
Thanks,
Amrita Kumari
Research Fellow
IISER Mohali
Chandigarh
INDIA
--
http
13 matches
Mail list logo