[Chimera-users] select by color (or other display attributes)

Oliver Clarke olibclarke at gmail.com
Thu Apr 2 16:16:31 PDT 2015

Elaine, that is exactly what I was looking for, and it works for selection too, thank you! 

So I can make an alias as follows which will select all things (except volumes - I’m not sure what the attribute for surface color is - surfacecolor doesn’t seem to work) of a particular color, if that color is a single word - I don’t know how to supply an argument to an alias which includes spaces (selbycolor “cornflower blue” doesn’t work, for example).

alias ^selbycolor sel :/ribbonColor="$1" | :/color="$1" | @/color="$1”

Thanks again,


> On Apr 2, 2015, at 6:29 PM, Elaine Meng <meng at cgl.ucsf.edu> wrote:
> Hi Oliver,
> If you actually colored something a color explicitly (as opposed to with rainbow or rangecolor), then you can specify the atoms and ribbon with that color, e.g.
> color pink  @/color=red
> color pink  :/ribbonColor=red
> would change to pink the red atoms/bonds and per-residue ribbon segments.  These and other attribute names (display etc.) are listed in the Attributes section of the atomspec documentation and/or you can see them by mousing over attribute inspector dialogs such as the Selection Inspector.
> <http://www.rbvi.ucsf.edu/chimera/docs/UsersGuide/midas/frameatom_spec.html>
> 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
> On Apr 2, 2015, at 2:21 PM, Oliver Clarke <olibclarke at gmail.com> wrote:
>> Hi, one feature I would love to see in a future version of chimera is the capacity to select residues/atoms by color - this would be magic for modifying figures.
>> Example use case: I’ve made a figure in which some complicated selection or set of selections is colored medium blue, and another selection is colored red. I’ve saved the session for the figure, but I (stupidly)didn’t save the corresponding selections, and now I have to remember exactly what selections I used. If there was a “select by color” function, I could simply select all the atoms that are colored medium blue (or some other color ID), and change them to another color, without having to know which residues were in the original selection. 
>> Analagously, it would also be handy, although less frequently useful, to be able to select on the basis of whether a residue is displayed, or represented in a particular manner - in particular, being able to restrict selection to displayed atoms/residues would be useful to avoid inadvertent modification of undisplayed models or parts thereof.
>> Cheers,
>> Oliver.

More information about the Chimera-users mailing list