you can try to exclude the backbone from your selections using "not": 

select V27, (resi 27 and EXA) and not (name N+C+O) 
# I included the CA in this selection


This should select the residue atoms excluding the backbone (except CA). 

If you have hydrogens in the structure you may need to modify the selection to also exclude certain hydrogens:
select V27, (resi 27 and EXA) and not ((name N+C+O) or ((neighbor (name N+C+CA+O)) and elem H))

Now you should be able to color and display the object sequentially, without overlap:

show_as cartoon, all # secondary structure
show sticks, V27 # shows the residue as sticks (including CA)
color green, all # base color
color red, V27 and not CA # colors the residue red (excluding the CA)

Hope this solves the issue.



On Fri, Aug 22, 2014 at 12:33 AM, Markus Heller <mheller@cdrd.ca> wrote:
Hi all,

I'm stuck.  I'm trying to create a figure where I show a helix bundle, with select side chains shown as sticks.  I would like the helices to be green, and the side chains in different colors.  Easy enough, *but* the carbon color of the side chains supersedes the green color of the helices.

I tried to duplicate the object and show sticks for one objects and helices for the other, which works in terms of color, *but* now the cartoon_side_chain_helper doesn't work, since I'm displaying sticks and helices from 2 different objects.

How do I go about this?

Thanks and Cheers

PS: Here's my attempt:

# reset everything
delete all

# white background
bg_color white

# show valences
set valence, 1

# show valences inside rings, 0 = centered, 1 = inside
set valence_mode, 1

# antialias
set antialias = 1

# don't show backbone for cartoons
set cartoon_side_chain_helper, on

# keep standard helix, strand, loop representations
# other options: cartoon loop, cartoon rect,
# cartoon oval , cartoon tube
cartoon automatic

# Molscript-like edges for helices
set cartoon_fancy_helices = 1

# color inside of helices gray
set cartoon_highlight_color, gray

# load the PDB file

load example.pdb, EXA

# duplicate protein
copy EXA_dup, EXA

# hide everything
hide everything

# select protein
select prot, polymer

# show cartoon ribbon
show cartoon, EXA

# select helices
select heli, (ss h and EXA)
select heli_dup, (ss h and EXA_dup)

# color everything limon
color limon

# select residue of interest
select V27, (resi 27 and EXA)
select S31, (resi 31 and EXA)
select A34, (resi 34 and EXA)
select H37, (resi 37 and EXA)
select W41, (resi 41 and EXA)

# show sticks for ROIs
show sticks, (V27 or S31 or A34 or H37 or W41)

# color ROIs
color atomic, (V27 or S31 or A34 or H37 or W41)
color yellow, (name C* and V27)
color orange, (name C* and S31)
color cyan, (name C* and A34)
color magenta, (name C* and H37)
color purple, (name C* and W41)

# color helices properly
show cartoon, EXA_dup
color limon, EXA_dup

# deselect all to avoid little pink squares

Markus Heller, Ph.D.
NMR Scientist
CDRD - The Centre for Drug Research and Development
2405 Wesbrook Mall, Fourth Floor | Vancouver, BC  V6T 1Z3 | Main: (604) 827-1147
Direct: (604) 827-1122 | F: (604) 827-1299 | E: mheller@cdrd.ca | www.cdrd.ca

Follow us:    

This email and any files transmitted with it are confidential and intended solely for the addressee.  If you are not the named addressee you should not disseminate, distribute, copy, or alter this email.

Slashdot TV.
Video for Nerds.  Stuff that matters.
PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net)
Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net