<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>On Dec 28, 2014, at 2:09 AM, Enrico Ronca <<a href="mailto:enrico@thch.unipg.it">enrico@thch.unipg.it</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div dir="ltr">Dear Sir.<div><br></div><div>I'm Enrico Ronca a post-doc researcher at the National Research Council of Italy in Perugia.</div><div><br></div><div>I'm contacting you because I often work with metal atoms and not always chimera show me bonds.</div><div>I solved the problem removing all bonds and pseudo bonds and adding "reasonable bond between selected atoms" in the adjust bonds menu of chimera.</div><div><br></div><div>Is there a way to run the same procedure from the command line so that I could automate it by a script?</div></div></blockquote><br></div><div>Hi Enrico,</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>There is no command line equivalent for the "all reasonable bonds" function, nor is there a command for deleting pseudobonds. So you have to resort to Python. Basically collating the "reasonable bond" code (from the _addBonds method in <your Chimera installation>/share/BuildStructure/gui.py) with custom code to close metal pseudobond groups and then additional calls to regular Chimera commands to select atoms and delete bonds. I've attached a file (rebond.py) that contains all that code. If you put the file in your home directory, then the command "open ~/rebond.py" will execute the code and do what you want.</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Normally I would not recommend adding "normal" (covalent) bonds rather than pseudobonds to metal ions since that will screw up many chemistry related functions in Chimera (<i>e.g.</i> adding hydrogens; finding H-bonds; minimization) but I suppose you know what you're doing! Maybe these are actual metal compounds instead of coordination complexes?</div><div><br></div><div>--Eric</div><br><div apple-content-edited="true">
<span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Helvetica" size="5" style="font: 16.0px Helvetica"><span class="Apple-converted-space"> <span class="Apple-converted-space"> </span></span>Eric Pettersen</font></p><p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Helvetica" size="5" style="font: 16.0px Helvetica"><span class="Apple-converted-space"> <span class="Apple-converted-space"> </span></span>UCSF Computer Graphics Lab</font></p><p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Helvetica" size="5" style="font: 16.0px Helvetica"><span class="Apple-converted-space"> </span><a href="http://www.cgl.ucsf.edu">http://www.cgl.ucsf.edu</a></font></p><br class="Apple-interchange-newline"></span>
</div>
</body></html>