VMD-L Mailing List
From: Marc Baaden (baaden_at_smplinux.de)
Date: Wed Oct 30 2002 - 11:52:09 CST
- Next message: Stéphane Teletchéa: "A vmd bug 1.8a28"
- Previous message: Justin Gullingsrud: "Re: helices in coil"
- In reply to: John Stone: "Re: positioning a protein with trans etc."
- Next in thread: eric hu: "xyz movie"
- Reply: eric hu: "xyz movie"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Hi John,
thanks for your suggestions.
I had a look at the various things you suggested. In the end I did a
coordinate transformation, but without a fit to another structure, just
using VMD commands to define the transformation matrices. The (experimental)
code I am currently using is attached below.
Thanks,
Marc
johns_at_ks.uiuc.edu said:
>> Hi Marc,
>> I still think that using (well, abusing in this case :-) the
>> best-fit code in VMD is the easiest way to do what you need: Rather
>> than fit the whole structure, just fit 3 atoms of interest, just as
>> you say, something in the center, some residue X pointing out of the
>> screen, and some residue Y pointing in another consistent direction.
>> You'll need at least 3 atoms to come up with correction matrix to
>> bring the other structures into the same viewing orientation. [..]
The little code snippet below uses the geom_center routine from the VMD
user manual. You invoke it with something like
position_view "protein and name CA" "protein and resid 714"
# POSITION_VIEW
# center on the geometrical center of the specified selection, and orient the
# central axes -> $rot_sel vector along the x axis
#
proc position_view { cen_sel rot_sel } {
# Move protein center to 0 0 0
set sel [atomselect top $cen_sel]
set cen [geom_center $sel]
set mat [ trans origin $cen ]
set move_sel [atomselect top "all"]
$move_sel move $mat
# Orient protein
set sel [atomselect top $rot_sel]
set cen [geom_center $sel]
set tmpx [ vecdot $cen { 1 0 0 } ]
set tmpy [ vecdot $cen { 0 1 0 } ]
set vec " [list $tmpx] [list $tmpy] 0 "
set mat [ transvecinv $vec ]
$move_sel move $mat
}
-- Dr. Marc Baaden - Laboratory of Molecular Biophysics, Oxford University mailto:baaden_at_smplinux.de - ICQ# 11466242 - http://www.marc-baaden.de FAX/Voice +49 697912 39550 - Tel: +44 1865 275380 or +33 609 843217
- Next message: Stéphane Teletchéa: "A vmd bug 1.8a28"
- Previous message: Justin Gullingsrud: "Re: helices in coil"
- In reply to: John Stone: "Re: positioning a protein with trans etc."
- Next in thread: eric hu: "xyz movie"
- Reply: eric hu: "xyz movie"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]