# [Chimera-users] display a coordinate system in view

Elaine Meng meng at cgl.ucsf.edu
Thu Oct 8 16:36:39 PDT 2015

```Hi Andy,
Well, you could open the attached BILD file (simple text format) to show coordinate axes. Scale, colors and origin can be edited, and you could open multiple copies. See BILD format description:

<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/bild.html>

However, the difficult part would be calculating the desired transformation from the domain movement to apply to these models at each step of your morph trajectory. It could be done within a per-frame script in the MD Movie tool (the tool that plays back the morph trajectory).  I haven’t tried it, but I imagine something like having an additional invisible copy of the structure with fixed coordinates, calculating the transformation that would be required to match some set of atoms in each domain from that fixed invisible model to their current position in the trajectory, and applying those transformations to the respective axis-object models.

<http://www.rbvi.ucsf.edu/chimera/docs/ContributedSoftware/movie/framemovie.html>
<http://www.rbvi.ucsf.edu/chimera/docs/ContributedSoftware/movie/movie.html#per-frame>

Per-frame scripts can be in Chimera commands or in Python (often needed if there aren’t commands to do what you need).  I tried using the “match” command with “move” specifying only the relevant axis-object model.  Unfortunately in a small test this didn’t work… I guess the “move” model has to be an atomic model, not an object (argh, so close and yet so far!).  Another thought is to actually move the the invisible model with “match" and then use the command “matrixcopy” to apply the same transformation to the  object model.  Then the per-frame script would also need to put the invisible model back to its original position, say with “reset” with its “move” option to move only the invisible model.

<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/midas/match.html>
<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/midas/matrixcopy.html>
<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/midas/reset.html>

I think this would work but I only did small tests of the various parts of my suggestion.
I hope this helps,
Elaine
----------
Elaine C. Meng, Ph.D.
UCSF Computer Graphics Lab (Chimera team) and Babbitt Lab
Department of Pharmaceutical Chemistry
University of California, San Francisco

-------------- next part --------------
A non-text attachment was scrubbed...
Name: XYZ-axes.bild
Type: application/octet-stream
Size: 297 bytes
Desc: not available
URL: <http://plato.cgl.ucsf.edu/pipermail/chimera-users/attachments/20151008/7fb06e6b/attachment.obj>
-------------- next part --------------

> On Oct 8, 2015, at 2:20 PM, Byrd, Robert A. (NIH/NCI) [E] <byrdra at mail.nih.gov> wrote:
>
> I would like to represent a xyz coordinate system by the unit vectors on the display with a molecule. Ideally, for a two domain protein, I would like to have two coordinate systems, one for each domain. In an ensemble of structures where one domain changes orientation with respect to the other, one coordinate system would move to the new position. It would be nice to then morph from one position to the next. This is straightforward with a set of structures and the morph utility in CHIMERA. The ability to add the two coordinate systems to the display, and have them ‘move’ or morph from one position to the other, would highlight the geometrical averaging that takes place.
>
> Is this possible in CHIMERA?
>
> Thanks
> Andy Byrd

```