Of course you're all correct - Thierry Fischmann already emailed me to correct me :)
I hadn't actually tested anything (mea culpa). I was just trying to point out for those of us less familiar with python that there were alternatives to doing this relatively simple thing outside of pymol. Apologies to the list, Jed Robert Campbell wrote: > Hi Jed, > > On Mon, 22 Mar 2010 10:23:34 -0400 Jed Goldstone <jgoldst...@whoi.edu> wrote: > > >> Of course, you could just use the .pdb file as a text file: >> >> grep CA xxxx.pdb | cut -f 2,4,7,8,9 >> >> will get you the amino acid number, the amino acid identity, and x,y,z >> coordinates for the CA. >> > > Often this will work, but unfortunately it is not fool proof. If there is > no chain ID, if the residue numbers are greater than 999 or if there are > alternate position characters present on the atom names, then your field > counts in your "cut" command will be off. The PDB file is very strict about > which character columns contain which information and there is no requirement > for spaces between those data columns. > > Cheers, > Rob > -- ------------------------ Jed Goldstone Research Specialist Woods Hole Oceanographic Institution Redfield 3-52 MS#32 Woods Hole, MA 02543 http://www.whoi.edu/hpb/Site.do?id=481 Phone: 508-289-4823 ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ PyMOL-users mailing list (PyMOL-users@lists.sourceforge.net) Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net