-
Notifications
You must be signed in to change notification settings - Fork 116
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
pdbfixer is mislabeling built residues with negative res IDs #175
Comments
Where did you find a PDB file with negative residue numbers? Residue numbers are supposed to be the index within the SEQRES section, which by definition can never be negative. |
In my test case, it's coming from a
I think the scientific origin of this is when people want to number their residues based on a pre-existing sequence alignment. |
Ok, that makes sense. Your solution looks fine. Note that when PDBFixer calls PDBFile.writeFile(), it specifies |
oops, didn't mean to close it. 😄 |
Good point. So PDBFixer really doesn't need to do this. |
In this line
PDBFixer is wrapping negative residue numbers around 10000, meaning that a residue whose number is supposed to be -4 is ending up as 9996.
One fix would look like this:
which is closer to what happens in OpenMM
Or even simpler would be to not do the modulo in PDBFixer since OpenMM does it.
The text was updated successfully, but these errors were encountered: