VMD-L Mailing List
From: Ana Celia Vila Verde (acavilaverde_at_gmail.com)
Date: Tue May 08 2012 - 09:31:23 CDT
- Next message: Axel Kohlmeyer: "Re: counting specific atom types"
- Previous message: Axel Kohlmeyer: "Re: flashing the VMD"
- In reply to: winardi, erik: "counting specific atom types"
- Next in thread: Axel Kohlmeyer: "Re: counting specific atom types"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Hi Erik,
To get the number of atoms of type Csp3 you can do:
# select the atoms you want
set sel [atomselect top "type Csp3"]
# have a look at
http://www.ks.uiuc.edu/Research/vmd/vmd-1.8.3/ug/node107.html for the
explanation of the command
set numAtoms [$sel num]
puts " the number of Csp3 atoms is $numAtoms"
# you should always delete selections to save memory
$sel delete
Cheers!
Ana
On 5/8/12 3:37 PM, winardi, erik wrote:
> Hi VMD users,
>
> Is there any command to count a specific atom types ?
> For example if the system has two types of C (Csp3 as type 1 and Csp2
> as type 2)
> How can I count the number of atom for each type carbon ?
>
> Thanks,
> Erik Winardi
- Next message: Axel Kohlmeyer: "Re: counting specific atom types"
- Previous message: Axel Kohlmeyer: "Re: flashing the VMD"
- In reply to: winardi, erik: "counting specific atom types"
- Next in thread: Axel Kohlmeyer: "Re: counting specific atom types"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]