From: Axel Kohlmeyer (akohlmey_at_gmail.com)
Date: Tue Oct 25 2011 - 08:03:13 CDT

On Sun, Oct 23, 2011 at 3:24 PM, Michael LeVine <mlevine_at_wesleyan.edu> wrote:
> Hi all,
>
> I am looking to draw a volume, and then count the number of residues
> in that volume. For example, if I create an occupancy volume for all
> resname A, I would like to then see how many resname B are within that
> volume, but I can't seem to find a way to select residues based on
> being within a volume. Also, I see that when I create a volume, the

you cannot do that. to determine atoms within a given volume,
you have to do a selection using comparisons based on coordinates.
for example.

set sel [atomselect top "x > -10.0 && x < 10.0"]

please keep in mind that the selection language
is entirely focused on selecting atoms.

> VMD terminal displays the number of voxels. I'd like to write a script
> that creates a volume for each frame of my trajectory and outputs the
> number of voxels. Is their a command which can output the number of
> voxels in a volume, like $sel num outputs the number of atoms in a
> selection? Sorry if this question isn't clear, I am new to using tcl
> scripts in VMD to calculate properties, and have limited programming
> experience. Thank you!

please have a look at the various measure commands.
perhaps something among them like measure sasa
is coming close to what you are looking for.

cheers,
    axel.

>
> Michael V. LeVine
> Weill Medical College of Cornell University
> Graduate School of Medical Sciences
> Program in Physiology, Biophysics & Systems Biology
>

-- 
Dr. Axel Kohlmeyer
akohlmey_at_gmail.com  http://goo.gl/1wk0
Institute for Computational Molecular Science
Temple University, Philadelphia PA, USA.