| 1 | #
|
|---|
| 2 | # Color zone the first surface using the selected atoms and radius set below.
|
|---|
| 3 | #
|
|---|
| 4 | from chimera import selection as s, openModels as om
|
|---|
| 5 | from _surface import SurfaceModel
|
|---|
| 6 | radius = 5
|
|---|
| 7 | surface = om.list(modelTypes = [SurfaceModel])[0]
|
|---|
| 8 | xform_to_surface = surface.openState.xform.inverse()
|
|---|
| 9 | atoms = s.currentAtoms()
|
|---|
| 10 | bonds = s.currentBonds()
|
|---|
| 11 | import ColorZone as cz
|
|---|
| 12 | points, colors = cz.points_and_colors(atoms, bonds, xform_to_surface)
|
|---|
| 13 | cz.color_zone(surface, points, colors, radius, auto_update = True)
|
|---|