From: Axel Kohlmeyer (
Date: Thu May 29 2014 - 11:59:26 CDT

On Thu, May 29, 2014 at 12:22 PM, Ricard Argelaguet <> wrote:

> I need to calculate the RMSF for all CA atoms for 500 trajectories, so I
> need to automatize the computation.
> I have the following script:
> proc rmsf_all_ca {} {
> set file_name "Calfa-rmsf.dat"
> set outfile [open $file_name w];
> set sel [atomselect top "resid 1 to 198 and name CA"]
> set mol [$sel molindex]
> for {set i 0} {$i < [$sel num]} {incr i} {
> set rmsf [measure rmsf $sel]
> puts $outfile "[expr {$i+1}] [lindex $rmsf $i]"
> }
> close $outfile
> }
> However, I am encountering the following problem: In order to calculate
> RMSF, I need to align first, and I usually do it manually with the VMDTT.
> But now I have to automatize that step. I know about the use of measure fit
> to align and calculate RMSD. However, for RMSF is more complicated as I do
> not have a single reference frame.

‚Äčthe vmd trajectory tool is nothing else but a Tcl/VMD script with some GUI
added. so all the pieces of script code you need should be in that script.
it may take some testing and all the GUI code may be a bit confusing, but
with some luck, you should find the core code blocks that do what you need
and then you can rewrite them from your script.


> Any idea??
> Thanks!

Dr. Axel Kohlmeyer
College of Science & Technology, Temple University, Philadelphia PA, USA
International Centre for Theoretical Physics, Trieste. Italy.