[Chimera-users] command lines to replace "joint models"

Eric Pettersen pett at cgl.ucsf.edu
Mon Jul 15 16:48:53 PDT 2019

Hi Daojiong,
	There is no command for “Join Models”, but the Python equivalent isn’t too difficult.  Let’s assume you’ve selected the C and N atoms by whatever means (and only those atoms), then this Python code would be the “Join Models” equivalent:

from chimera.selection import currentAtoms
a1, a2 = currentAtoms()
if a1.element.name == “C”:
	c, n = a1, a2
	c, n = a2, a1

length = 1.33
dihedral = 180.0
phi = -120
from BuildStructure import cnPeptideBond
cnPeptideBond(c, n, n, length, dihedral, phi=phi)

	If you put the above Python code into a file whose name ends in .py, then you can run it simply by opening the file.  So if you named the file peptide.py, then something like this:

sel something-that-selects-just-C-and-N
open peptide.py

	I have attached the Python file because my mail program changes simple quotation marks into fancy ones that aren’t correct in Python.


	Eric Pettersen
	UCSF Computer Graphics Lab

> On Jul 15, 2019, at 12:01 AM, wangdj7 at mail.ustc.edu.cn wrote:
> Dear Chimera developers,
> I'm so sorry to interrupt you.
> I have to run Chimera in Linux,but there is no command line of  "joint modeles".I need to get 2 modified amino acids or peptides together and not creating crashes.In windows,"joint models" is my best choice,it's very convient and perfect.But in Linux,I tried some command line,such as "combine","bond",but it can't automatically repositioning the models and the structure was not right.
> So,could you please tell me how to use command lines to replace "joint models" function?
> Thanks in advance
>  Best Regards
>  Daojiong Wang
> _______________________________________________
> Chimera-users mailing list: Chimera-users at cgl.ucsf.edu
> Manage subscription: http://plato.cgl.ucsf.edu/mailman/listinfo/chimera-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://plato.cgl.ucsf.edu/pipermail/chimera-users/attachments/20190715/ad612817/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: peptide.py
Type: text/x-python-script
Size: 264 bytes
Desc: not available
URL: <http://plato.cgl.ucsf.edu/pipermail/chimera-users/attachments/20190715/ad612817/attachment.bin>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://plato.cgl.ucsf.edu/pipermail/chimera-users/attachments/20190715/ad612817/attachment-0001.html>

More information about the Chimera-users mailing list