From: bo baker (bo.bybaker_at_gmail.com)
Date: Mon Aug 11 2008 - 06:31:12 CDT

Hello, Axel:

Thank you very much! Your script is the one that I need exactly. And
it works perfect.

Just one more question here. Instead of "atomselect", could I ask VMD
to just select the residues?

Cheers

Bo

On 8/11/08, Axel Kohlmeyer <akohlmey_at_cmm.chem.upenn.edu> wrote:
> On Sun, 10 Aug 2008, bo baker wrote:
>
> BB> Hello,
>
> hello bo,
>
> BB> I use VMD to do some analysis works on the residues between the
> BB> interaction site from two protein. From "graph presentation", I select
> BB> the residues "chain B and within 5 of chain A". It returns several
> BB> residues in the main display. In order to know all these residues, I
> BB> use "lable" to click on each.
> BB>
> BB> I need to exam a large amount conformations of the complex later on.
> BB> It is time consuming to write down the residues from each
> BB> conformation, plus easy to make a mistake. I wonder if there is a way
> BB> that I could save my selections, I mean the residue ID in text form,
> BB> and plot them later?
>
> this is what can be done best using the tcl (or python) scripting
> interface in VMD. have a look at the corresponding descriptions and
> examples in the VMD user's guide and the tutorials referred to from
> the VMD home page.
>
> for your specific example you'd do something like
>
> set sel [atomselect top "chain B and within 5.0 of chain A"]
>
> and then you can get the information you want through:
>
> set res [$sel get {index name resname resid}]
>
> which returns a list lists with several pieces of information
> about each atom in the selection, i.e. here a list of the
> atom index, atom name, residue name, residue id.
>
> please note, that resid is the number from the .psf file
> and "residue" is the unique number vmd assigns to each
> residue (similar to index).
>
> cheers,
> axel.
>
>
> BB>
> BB> Thank you for your help.
> BB>
> BB> Bo
> BB>
>
>
> --
> =======================================================================
> Axel Kohlmeyer akohlmey_at_cmm.chem.upenn.edu http://www.cmm.upenn.edu
> Center for Molecular Modeling -- University of Pennsylvania
> Department of Chemistry, 231 S.34th Street, Philadelphia, PA 19104-6323
> tel: 1-215-898-1582, fax: 1-215-573-6233, office-tel: 1-215-898-5425
> =======================================================================
> If you make something idiot-proof, the universe creates a better idiot.
>