[chimera-dev] Detecting Differences in Hydrogen Placement in PDB Files

Elaine Meng meng at cgl.ucsf.edu
Fri Sep 25 11:22:37 PDT 2020


Hi Alexander,
This list (chimera-dev address) is for programming questions, whereas the chimera-users at cgl.ucsf.edu address is better for general questions by people who would prefer not to write code; I will answer for the latter.  Not sure which kind of answer you were trying to get.

I am guessing the heavy (nonhydrogen) atoms are in exactly the same positions, and only some or all of the hydrogens are different.

Of course you can just open the two files, display all the hydrogens, color the two structures two different colors and see where they are different, e.g. if I had file1.pdb and file2.pdb, commands something like the following (you should substitute your own file names and locations, of course)

open /Users/meng/Desktop/file1.pdb
open /Users/meng/Desktop/file2.pdb
~ribbon
display
rainbow models

However, it can be hard to visually identify all the differences, or maybe you want to save just the different atoms to a file. Maybe "find clashes" could be used to select all atoms of file1 that are in basically the same position as atoms of file2, and then you could invert the selection to find only the OTHER atoms (not in the same position).

Chimera and our newer program ChimeraX both have a "find clashes" tool but currently only the latter has the option I want to use, to use center-to-center distance instead of VDW overlap.  So you would have to use ChimeraX if you want to try this part.  The Chimera commands given above would also work in ChimeraX (except "rainbow models" should be "rainbow structures" instead), but the following are for ChimeraX only:

clashes #1 restrict #2 distanceOnly 0.01 select true
sel ~ sel

... then only the "different" atoms are selected.  You would have to decide for yourself what distance should define "different" and use it instead of the 0.01 I put in the example.   Then you can do something to the selected atoms, like label them or color them (see Actions menu) or write them to a PDB file, e.g. something like

save /Users/meng/Desktop/differences.pdb relModel #1 selectedOnly true

... possibly also including in that command "models #1" or "models #2" if you only want to write the atoms from one structure or the other instead of both together.

ChimeraX save PDB command:
<http://rbvi.ucsf.edu/chimerax/docs/user/commands/save.html#pdb>
ChimeraX User Guide including help for all commands:
<http://rbvi.ucsf.edu/chimerax/docs/user/index.html>

(Separate from Chimera, ChimeraX has its own website, download page, chimerax-users at cgl.ucsf.edu help list etc.)

Chimera commands help:
<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/framecommand.html>

I hope this helps,
Elaine
-----
Elaine C. Meng, Ph.D.                       
UCSF Chimera(X) team
Department of Pharmaceutical Chemistry
University of California, San Francisco

> On Sep 25, 2020, at 10:21 AM, Alexander Novokhodko <novalex at uw.edu> wrote:
> 
> Dear Chimera User List,
> 
> Could you please help me figure out how to detect differences in hydrogen placement between two Chimera files? I have two structures of the same protein with hydrogens placed by different programs, and I have differences in hydrogen bonding that I'm trying to explain. Thus, I would like to know where the hydrogens were placed and in particular, where they were placed differently. Please help!
> 
> Thank you,
> Sincerely,
> Alexander Novokhodko




More information about the Chimera-dev mailing list