VMD-L Mailing List
From: Monika Madhavi (monikamadhavi_at_gmail.com)
Date: Thu Jan 28 2016 - 23:11:57 CST
- Next message: Davide Mercadante: "Re: Extracting velocity information from .gro or .trr files"
- Previous message: John Stone: "Re: Extracting velocity information from .gro or .trr files"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Dear all,
I want to select few atoms first (of which indices are stored in a list)
and select each atom in the list from the trajectory. I wrote this tcl code
set atomlist [read $input]
set len [llength $atomlist]
for {set i 0} {$i <= $len} {incr i} {
set ind1 [lindex $atomlist $i]
set mol [mol new mypsf.psf type psf waitfor all]
for {set frm 0} {$frm <= $n} {incr frm} {
mol addfile mydcd.dcd type dcd first $frm last $frm waitfor all molid $mol
set sel [atomselect $mol "index $ind1" frame $frm]
}
}
when the same code is written without the loop to select "ind1" the code
works fine. But when I try this it says "atomselect: cannot parse selection
text: index"
Any help to solve this problem is much appreciated.
Thank you.
Monika
-- W.A.Monika Madhavi Lecturer (Probation), Department of Physics, University of Colombo.
- Next message: Davide Mercadante: "Re: Extracting velocity information from .gro or .trr files"
- Previous message: John Stone: "Re: Extracting velocity information from .gro or .trr files"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]