Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.pdb coordinate reader can be improved #56

Open
nabraham47 opened this issue May 29, 2019 · 2 comments
Open

.pdb coordinate reader can be improved #56

nabraham47 opened this issue May 29, 2019 · 2 comments
Labels

Comments

@nabraham47
Copy link

The get_coordinates_pdb function in calculate_rmsd.py would benefit from the inclusion of 'HETATM' when reading in coordinates and atoms.

if line.startswith("ATOM"):

I was able to change line 688 to:
if line.startswith("ATOM") or line.startswith("HETATM"):

This allowed the program to also read in .pdb's formatted with HETATM

@charnley
Copy link
Owner

charnley commented Jun 7, 2019

Hi @nabraham47 ,

I am very rarely a .pdb format user but there seems to be one or more issues with the PDB reader. (like #57 ) If you open up a pullrequest with the changes I will accept the changes.

nbehrnd added a commit to nbehrnd/rmsd that referenced this issue Jun 11, 2019
As by [1] as by experience writing .pdb with openbabel [2],
lines about atom coordinates may start by either 'ATOM', or
'HETATOM' as keyword.  The addition of the later widens the
scope of calculate_rmsd.py, an additional condition to work
well with e.g. openbabel-written .pdb.  The idea however was
deposit earlier by 'nabraham47' as issue charnley#56 (2019-May-30)
to the general attention.
[1] http://www.wwpdb.org/documentation/file-format-content/format33/sect9.html#ATOM
[2] www.openbabel.org
@nbehrnd
Copy link
Contributor

nbehrnd commented Jun 11, 2019

Hi @nabraham47 ,

your very valuable suggestion contributed to widen the potential scope of the script,
because openbabel, widely used to convert between chemistry relevant files, equally
uses HETATOM as a line instruction.

@charnley charnley added the bug label Sep 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants