From: Kshatresh Dutta Dubey (kshatresh_at_gmail.com)
Date: Sun Dec 14 2014 - 10:02:14 CST

Hi,

I want to analyze the number of water molecules/per frame within some
cutoff distance of residue of my simulated trajectories. I dont have
expertise of tcl scripting however I tried following scripts:

set outfile [open waters.dat w];
set nf [molinfo top get numframes]
set frame0 [atomselect top "water within 3 of resname HEM" frame 0]
set sel [atomselect top "water within 3 of resname HEM"]
for {set i 1 } {$i < $nf } { incr i } {
   $sel frame $i
   puts $outfile "[[ $sel $frame0] num] "
}
close $outfile

But every time it is stops with error: atomselection: improper method:
atomselect28, that means something is not right in last 3rd line.
I will be thankful if someone suggests me to figure out the issue.

Regards
Kshatresh