[Biopython-dev] [Bug 2949] _parse_pdb_header_list: REVDAT is for oldest entry.
bugzilla-daemon at portal.open-bio.org
bugzilla-daemon at portal.open-bio.org
Sat Mar 20 19:02:16 EDT 2010
http://bugzilla.open-bio.org/show_bug.cgi?id=2949
------- Comment #2 from crosvera at gmail.com 2010-03-20 19:02 EST -------
Currently I got this with the actual code:
bash-4.0$ python
Python 2.6.4 (r264:75706, Mar 10 2010, 15:54:34)
[GCC 4.4.1 (CRUX)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from Bio.PDB import *
>>> parser=PDBParser()
>>> structure = parser.get_structure("2beg", "../2BEG.pdb")
>>> structure.header.keys()
['structure_method', 'head', 'journal', 'journal_reference', 'compound',
'keywords', 'name', 'author', 'deposition_date', 'release_date', 'source',
'resolution', 'structure_reference']
>>> structure.header['release_date']
'2005-11-22'
>>>
but the grep command returns this:
bash-4.0$ grep REVDAT ../2BEG.pdb
REVDAT 3 24-FEB-09 2BEG 1 VERSN
REVDAT 2 20-DEC-05 2BEG 1 JRNL
REVDAT 1 22-NOV-05 2BEG 0
So, the actual code is showing the oldest date from REVDAT. I don't know if you
(the developer) are trying to say with 'release_date' if is the first version
or the last. But I think, as Paul said, that should be the most current date.
By the way, my previous comment I said that the last part of the code pasted by
Paul should be:
dict['mod_number'] = hh[7:9]
dict['mod_id'] = hh[23:26]
dict['mod_type'] = hh[31]
But it has to be:
dict['mod_number'] = hh[7:10]
dict['mod_id'] = hh[23:27]
dict['mod_type'] = hh[31]
Other thing, instead to add 'mod_number', 'mod_id', 'mod_type' directly into
dict. I think that these keys should be inside a 'release_data' key:
dict={'name':"",
[...]
'release_date' : "1909-01-08",
'release_data' : {'mod_number' : "", 'mod_id' : "", 'mod_type' :
""},
'structure_method' : "unknown",
[...]
}
Please comment :)
Regards.
--
Carlos Rios V.
--
Configure bugmail: http://bugzilla.open-bio.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the Biopython-dev
mailing list