Color Binding Site Object by Electrostatic Potential Grid

PURPOSE: The script works on the last active document which should contain both an Isosurface (grid) object and a set of selected (or visible) binding site points. The script finds the nearest grid point to each binding site point and colors it according to the potential value of that grid point. The binding site points are converted to (potassium) atoms and are displayed as balls with 0.2 angstrom radius. The color spectrum used is BlueWhiteRed and the user can either enter the Maximum and Minimum potential range or it can be calculated from the minimum and maximum values of the nearest grid points.

INSTALLATION: Save color_BindingSite_bygrid.pl to a local directory or location accessible from the Files Explorer

USAGE:
From the DS Client: From the Files Explorer, double-click on the color_BindingSite_bygrid.pl to launch the script or right-click on the file and select Open With | Script Window then launch the script using the Run command from the Scripting toolbar.

REQUIREMENTS: This script will run on the most recently viewed Molecule Window.
The window should contain an Isosurface (grid) and a 'molecule' with the name BindingSite
which was generated using 'Convert to Atoms'.
*** Adjustable parameter are found at lines 43 through 47. Refer to comments in that section for parameter description.

DISCLAIMER: This custom script is compatible with Discovery Studio 2.5. It is provided "as is" and is NOT supported by Accelrys nor is it warranted for any purpose whatsoever. The user assumes responsibility for any malfunctions or bugs.

EXPECTED RESULTS: The attached zip file contains an image illustrating the expected results i.e. a binding site displayed as atoms colored red, white or blue according to their electrostatic potential.