<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hi Matthias,<div class="">The "contacts" or "clashes" command gives all-by-all distances (and VDW overlaps) between two sets of atoms. You can write all the info to a file or to a log. It does not automatically only give you the shortest distance, but it sorts the output so that the shortest is first.</div><div class=""><br class=""></div><div class="">For example (these structures are nonphysically on top of each other, but work for illustrating the commands):</div><div class=""><br class=""></div><div class="">open 1zik</div><div class="">open 1gcn</div><div class="">contacts #1 restrict #2 distanceOnly 5 log true</div><div class=""><br class=""></div><div class="">...shows in the log all the pairwise distances between the two sets of atoms that are within 5 angstroms, with the shortest distance first.</div><div class=""> </div><div class="">See measurements:</div><div class=""><<a href="https://rbvi.ucsf.edu/chimerax/docs/user/measurements.html" class="">https://rbvi.ucsf.edu/chimerax/docs/user/measurements.html</a>></div><div class=""><br class=""></div><div class="">Clashes or contacts command:</div><div class=""><<a href="https://rbvi.ucsf.edu/chimerax/docs/user/commands/clashes.html" class="">https://rbvi.ucsf.edu/chimerax/docs/user/commands/clashes.html</a>></div><div class=""><br class=""></div><div class="">For scripting, instead of "log" you could use "saveFile" to get an output file for each structure pair. What you get in the Log or file looks like this:</div><div class=""><br class=""></div><div class=""><font face="Courier" class=""><span style="font-style: normal;" class="">Ignore distances between atoms separated by 4 bonds or less<br class="">Detect intra-residue distances: False<br class="">Detect intra-molecule distances: True<br class=""><br class="">3030 distances<br class=""> atom1 atom2 overlap distance<br class="">1gcn #1/A ARG 18 CZ 1zik #2/A LYS 15 O 4.767 0.233<br class="">1gcn #1/A LYS 12 O 1zik #2/A VAL 9 CA 4.568 0.432<br class="">1gcn #1/A ARG 18 CD 1zik #2/A LYS 16 CA 4.540 0.460<br class="">1gcn #1/A ALA 19 O 1zik #2/B LYS 15 CB 4.449 0.551<br class="">1gcn #1/A TRP 25 CE3 1zik #2/B GLU 22 CB 4.415 0.585<br class="">1gcn #1/A SER 8 OG 1zik #2/A LYS 3 CE 4.407 0.593<br class="">1gcn #1/A PHE 22 CE2 1zik #2/B HIS 18 N 4.392 0.608<br class="">1gcn #1/A LYS 12 NZ 1zik #2/A LEU 5 CB 4.356 0.644<br class="">1gcn #1/A LYS 12 CD 1zik #2/A LEU 5 O 4.335 0.665<br class="">1gcn #1/A GLN 20 CA 1zik #2/B LYS 15 CD 4.309 0.691<br class="">[... etc. ...]</span></font></div><div class=""><br class=""></div><div class="">I hope this helps,</div><div class="">Elaine</div><div class=""><div class="">-----<br class="">Elaine C. Meng, Ph.D. <br class="">UCSF Chimera(X) team<br class="">Department of Pharmaceutical Chemistry<br class="">University of California, San Francisco<br class=""><br class=""></div><blockquote type="cite" class="">On Sep 28, 2021, at 2:15 AM, Vorländer,Matthias Kopano via ChimeraX-users <<a href="mailto:chimerax-users@cgl.ucsf.edu" class="">chimerax-users@cgl.ucsf.edu</a>> wrote:<br class=""><br class="">Dear all, <br class="">I am interested in measuring the shortest distance between two models (PDBs) without a priori knowledge of which atoms will be the closest ones. I am planning to do this for a large number of model pairs, therefore it would be great if this would be scriptable. Is this possible using ChimeraX?<br class="">Thanks a lot in advance, <br class="">Best,<br class="">Matthias<br class=""></blockquote><br class=""></div></body></html>