VMD-L Mailing List
From: Bo Liu (boliu_at_ks.uiuc.edu)
Date: Mon Nov 08 2010 - 09:23:24 CST
- Next message: Prskalo, Alen-Pilip: "Graphics card for VMD, number of atoms, file format"
- Previous message: aneesh cna: "Script for counting water molecules"
- In reply to: divya nayar: "fit.tcl"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
*fit selection1 selection2 [weight weight] [order index list]*: Returns a
4x4 transformation matrix which, when applied to the atoms in *selection1*,
minimizes the weighted RMSD between *selection1* and *selection2*. See
section 12.4.2<http://www.ks.uiuc.edu/Research/vmd/current/ug/node197.html#ug:scripts:rmsd>
for more on RMSD alignment. The optional flag *order* takes as argument a
list of 0-based indices specifying how to reorder the atoms in
*selection2* (Example:
To reverse the order of atoms in a selection containing 10 atoms one would
use order {9 8 7 6 5 4 3 2 1 0}).
This is documented at
http://www.ks.uiuc.edu/Research/vmd/current/ug/node133.html
Besides doing the tutorial, read the user's guide if you are serious with
VMD.
On Mon, Nov 8, 2010 at 3:01 AM, divya nayar <divya.alchemist_at_gmail.com>wrote:
> Hi,
> I am using fit.tcl to fit the frames of my MD trajectory with the reference
> frame 0. I am studying a system of solvated peptide. Can anyone tell me how
> the command 'fit' works? VMD tutorial says something regarding 4X$ matrix
> transformation. Can anyone tell me a frerence to this or explain what
> exactly happens when we fit a frame to a reference frame. The tcl script is
> as follows:
>
>
> ## This takes a selection and fits that selection for every frame in the
> ## molecule (all atoms are moved, but the fit is based on the selection).
> ##
> ## For example: fitframes top "protein"
> ##
> ## -Jim
> proc fitframes { molid seltext } {
> set ref [atomselect $molid $seltext frame 0]
> set sel [atomselect $molid $seltext]
> set all [atomselect $molid all]
> set n [molinfo $molid get numframes]
>
> for { set i 1 } { $i < $n } { incr i } {
> $sel frame $i
> $all frame $i
> $all move [measure fit $sel $ref]
> }
> return
> }
>
> Thanks,
> Divya
>
-- ======================================== Bo Liu Theoretical and Computational Biophysics Group 3027 Beckman Institute University of Illinois at Urbana-Champaign 405 N. Mathews Urbana, IL 61801 http://www.ks.uiuc.edu/~boliu ========================================
- Next message: Prskalo, Alen-Pilip: "Graphics card for VMD, number of atoms, file format"
- Previous message: aneesh cna: "Script for counting water molecules"
- In reply to: divya nayar: "fit.tcl"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]