Extracting data

From: Stephan Grein (grein_at_informatik.uni-frankfurt.de)
Date: Wed Feb 04 2015 - 05:55:37 CST

Dear NAMD users,

i want to extract information from my DCD file as follows:

   set from {1 10 20 30}
   set to {40 50 60 70}
   set from_len [lindex $from]
   set to_len [lindex $to]
   set steps_start 101

   for {set i $steps_start} {$i < $num_steps} {incr i} {
      for {set j 0} {$j < $from_len} {incr j} {
         for {set k 0} {$k < $from_len} {incr k} {
            set mysel1 [atomselect top "index [lindex $from $j]"]
            set mysel2 [atomselect top "index [lindex $to $k]"]
              # do something with the selection, then delete it
           $mysel1 delete
           $mysel2 delete
     animate goto $i

But for me, this is horribly slow.
Is there any obvious failure in my snippet?

Would be glad, if someone could point it out.

Best regards,

This archive was generated by hypermail 2.1.6 : Tue Dec 27 2016 - 23:20:53 CST