From: John Stone (johns_at_ks.uiuc.edu)
Date: Mon Feb 28 2005 - 10:38:13 CST

Hi,
  I've made a better version of that per-residue SASA calculation/coloring
script. The first one did selections by "resid" but this can lead to
duplicate residues being selected from certain PDB files. I've rewritten it
to use "residue", which VMD should force to be unique. This ought to be
more robust than the other one.

##
## Example script that sets the "User" data field with SASA values
##
mol delete all
mol addfile 1tit

##
## Get list of residues (use 'residue' and not 'resid' so we don't get
## duplicate residues from unusual PDB files..)
##
set allsel [atomselect top all]
set residlist [lsort -unique [$allsel get residue]]

##
## Make an atom selection, set the User field with the SASA value for
## the selected atom
##
foreach r $residlist {
  set sel [atomselect top "residue $r"]
  set rsasa [measure sasa 1.4 $allsel -restrict $sel]
  $sel set user $rsasa
  $sel delete
  puts "residue $r, sasa: $rsasa"
}

##
## change the "color by" and "trajectory" tab settings to color by SASA
##
mol modcolor 0 [molinfo top] User
mol colupdate 0 [molinfo top] 1
mol scaleminmax [molinfo top] 0 auto

On Mon, Feb 28, 2005 at 10:17:54AM -0600, John Stone wrote:
>
> You're right that the "buried" keyword is a shortcut that's hardwired
> to match various residues, and it doesn't take into account the actual
> structure you've got loaded. Another method that likely has more merit,
> would be to calculate the solvent accessible surface area, and use that
> as your measure of "buried" or "surface" etc. You could run a script setting
> the user field for each residue with its SASA, and then use a selection like
> "user > 1.0" or something like that as a heuristic to determine which residues
> are exposed and which are not. One could even do this for all of the atoms
> invidually, but it would take a while to calculate. Try using the
> "user > 1.0" with a script like this one and let me know if that helps.
>
> ##
> ## Example script that sets the "User" data field with SASA values
> ##
> mol delete all
> mol addfile 1ap9
>
> ##
> ## Get list of residues
> ##
> set allsel [atomselect top all]
> set residlist [lsort -unique [$allsel get resid]]
>
> ##
> ## Make an atom selection, set the User field with the SASA value for
> ## the selected atom
> ##
> foreach r $residlist {
> set sel [atomselect top "resid $r"]
> set rsasa [measure sasa 1.4 $allsel -restrict $sel]
> $sel set user $rsasa
> $sel delete
> puts "resdidue $r, sasa: $rsasa"
> }
>
> ##
> ## change the "color by" and "trajectory" tab settings to color by SASA
> ##
> mol modcolor 0 [molinfo top] User
> mol colupdate 0 [molinfo top] 1
> mol scaleminmax [molinfo top] 0 auto
>
>
>
>
> On Mon, Feb 28, 2005 at 02:42:52PM +0100, Mgr. Lubos Vrbka wrote:
> > hi all,
> >
> > i guess this must have been asked before, but i couldn't find any
> > solution to my problem. i want to get list of all residues defining a
> > surface of my protein. i know i can do "surface" or "protein and not
> > buried" selection, but this doesn't seem to work ok. from what i've seen
> > in the documentation, "buried" is defined as
> > residues named ALA LEU VAL ILE PHE CYS MET TRP
> > so if any of the other residues is "buried" inside the protein, it
> > doesn't work correctly. does this mean, that some kind of assumption
> > "hydrophobic = buried" is made?
> >
> > is there any way how to get the desired information? will i'll have to
> > somehow parse surf/msms outputs?
> >
> > thank you for help. best regards,
> > lubos
> >
> > --
> > .....................................................
> > Mgr. Lubos Vrbka
> >
> > Center for Biomolecules and Complex Molecular Systems
> > Institute of Organic Chemistry and Biochemistry
> > Academy of Sciences of the Czech Republic
> > Prague, Czech Republic
> > .....................................................
>
> --
> NIH Resource for Macromolecular Modeling and Bioinformatics
> Beckman Institute for Advanced Science and Technology
> University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
> Email: johns_at_ks.uiuc.edu Phone: 217-244-3349
> WWW: http://www.ks.uiuc.edu/~johns/ Fax: 217-244-6078

-- 
NIH Resource for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
Email: johns_at_ks.uiuc.edu                 Phone: 217-244-3349              
  WWW: http://www.ks.uiuc.edu/~johns/      Fax: 217-244-6078