The “key” in your command tries to bring up the Color Key tool — which is impossible in nogui/headless mode.  There is no way to place a color key solely using commands, so if you really need a color key you would have to resort to using Python code to create it.  Otherwise, just drop “key” from your command and it will work.

—Eric

Eric Pettersen
UCSF Computer Graphics Lab

On May 14, 2018, at 12:33 PM, NAGARAJAN <nagabioinfostar@gmail.com> wrote:

Hi,

  Thank you for the suggestion. I have installed the headless version and now it is working. I tried to color the surface based on b-factor using the following commnad

  "rangecolor bfactor key 2 blue 30 red 50 yellow"

  it is showing the following error "No module named Togl"

  I referred in internet and it seems this module is removed automatically during updation.

 Any idea how to solve this problem?

Thank you

 

On Fri, May 11, 2018 at 6:31 PM, Eric Pettersen <pett@cgl.ucsf.edu> wrote:
This line from the “primer” that Elaine mentioned in her later message covers the problem you’re having:

Note that if your script creates images then you must start the Chimera interface unless you've downloaded the "headless" version of Chimera (see the download page).

—Eric


Eric Pettersen
UCSF Computer Graphics Lab




On May 11, 2018, at 4:25 PM, NAGARAJAN <nagabioinfostar@gmail.com> wrote:

Hi,

  Thanks for the quick reply. I have previous experience in using Chimera GUI but not in nogui.

  The main thing that I dont know is to use those commands in nogui mode.

   For example: for saving image, I have used "runCommand("copy str.png") . but it is now working

   Is there any link to get the informations to use commands in nogui mode

Thank you
  



On Fri, May 11, 2018 at 6:19 PM, Elaine Meng <meng@cgl.ucsf.edu> wrote:
Hi,
I guess you will be using commands.  Here are commands for your steps
1. open
2. surface
3. color
4, copy
Of course, you will have to include more things in those commands, various options, residue numbers, filenames etc. that you should test in the GUI first to make sure they do what you want.  See also the list of commands for anything else you might want to do like rotate (turn) translate (move) zoom (scale) … and click on the link to see each command’s help with information about the command syntax and  possible options.
<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/framecommand.html>

See also:
 getting started with commands
<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/tutorials/getting_started.html>

 tips for making nice images
<http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/print.html#tips>

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

> On May 11, 2018, at 4:09 PM, NAGARAJAN <nagabioinfostar@gmail.com> wrote:
>
> Hi all,
>    I have to use chimera --nogui and do the following
>
>   1. load a structure
>   2. make Surface representation
>   3. Color surface of selected residues with a selected color
>   4. save image
>
> Any idea how to do the 4 steps in chimera --nogui?
> Thank you



_______________________________________________
Chimera-users mailing list: Chimera-users@cgl.ucsf.edu
Manage subscription: http://plato.cgl.ucsf.edu/mailman/listinfo/chimera-users