VMD-L Mailing List
From: Lena Simine (lena.simine_at_rice.edu)
Date: Sun Apr 24 2016 - 00:46:23 CDT
- Next message: Jérôme Hénin: "Re: how do I keep graphics/representations in their designated frames? (they all show up in all frames)"
- Previous message: zeynab hoseyni: "Why wrapped and unwrapped trajectories show different energies over the time?"
- Next in thread: Jérôme Hénin: "Re: how do I keep graphics/representations in their designated frames? (they all show up in all frames)"
- Reply: Jérôme Hénin: "Re: how do I keep graphics/representations in their designated frames? (they all show up in all frames)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Hi,
Can't figure out how to prevent the added graphics or new
representations from "accumulating" in a trajectory.
I'd like to make a selection which differs in each frame and do
something to it, like add graphics or add a representation
for that selection in that frame alone.
Instead I end up with *all* of my graphics/representations on *all* frames..
Any clues how to fix this? (sorry, a total newb)
I'm doing something along the lines of this:
set n [ molinfo top get numframes ]
for {set i 0} {$i < $n} {incr i} {
set sel_text [lindex $data2 $i]
set sel2 [atomselect top "serial $sel_text"]
$sel2 frame $i
set xyz [$sel2 get {x y z}]
set xyz2 [split {*}$xyz]
graphics top sphere $xyz2 radius 4
}
or with representations
set n [ molinfo top get numframes ]
for {set i 0} {$i < $n} {incr i} {
set sel_text [lindex $data2 $i]
mol representation beads 1 68
mol selection $sel_text frame $i
mol material Transparent
mol addrep top
}
Cheers,
Lena
- Next message: Jérôme Hénin: "Re: how do I keep graphics/representations in their designated frames? (they all show up in all frames)"
- Previous message: zeynab hoseyni: "Why wrapped and unwrapped trajectories show different energies over the time?"
- Next in thread: Jérôme Hénin: "Re: how do I keep graphics/representations in their designated frames? (they all show up in all frames)"
- Reply: Jérôme Hénin: "Re: how do I keep graphics/representations in their designated frames? (they all show up in all frames)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]