From: John Stone (johns_at_ks.uiuc.edu)
Date: Tue Jun 24 2003 - 10:31:10 CDT

Ioana,
  You may need to use the '\' character to escape the '+' and '-'
characters in your atom selections since they are meaningful to
the regular expression parser. There are a few examples in the
VMD manual here:
  http://www.ks.uiuc.edu/Research/vmd/current/ug/node81.html#4963

Let us know if you still need help with this.

Thanks,
  John Stone
  vmd_at_ks.uiuc.edu

On Mon, Jun 23, 2003 at 02:16:02PM -0700, Ioana Cozmuta wrote:
> Hi,
>
> I am trying to set the K+ and Cl- atoms fixed in my structure. When I
> generate the representations I use
> resname "K+.*" and resname "Cl-.*" respectively
> However in the log file when I use
>
> mol new {23KClSpmBox.pdb} type {pdb} first 0 last -1 stride 1 waitfor 1
> set all [atomselect top all]
> set fix1 [atomselect top "resname "K+.*""]
> set fix2 [atomselect top "resname "Cl-.*""]
> $all set beta 0
> $fix1 set beta 1
> $fix2 set beta 1
> $all writepdb fixKCl_spm.pdb
> quit
>
> Could you help me figure out what is the correct way to define the residue
> name for K+ and Cl-?
>
> Thank you,
> Ioana

-- 
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