RE: [PyMOL] Swissprot

2004-10-20 Thread Warren DeLano
Jules,

Right now (and for the foreseeable future) PyMOL's sequence viewer shows
actual atoms in an object (whether or not they have coordinates).  There
isn't currently any way to retrieve that information other than by looking
at atoms...

model=cmd.get_model(object-name)
for atom in model.atom:
   print atom.name, atom.chain

etc.

PyMOL's C code isn't particularly object-oriented -- there is no class which
encapsulates the PDB parser.

Cheers,
Warren


--
mailto:war...@delsci.com
Warren L. DeLano, Ph.D.
Principal Scientist
DeLano Scientific LLC
400 Oyster Pt. Blvd., Ste 213
South San Francisco, CA 94080
(650)-346-1154  Fax:(650)-593-4020
  

 -Original Message-
 From: pymol-users-ad...@lists.sourceforge.net 
 [mailto:pymol-users-ad...@lists.sourceforge.net] On Behalf Of 
 Jules Jacobsen
 Sent: Monday, October 18, 2004 6:41 AM
 To: pymol-users@lists.sourceforge.net
 Subject: [PyMOL] Swissprot
 
 Hello List,
 
 I'm trying to make a plugin which will load various features 
 from a swissprot entry onto a model loaded in PyMol but need 
 to know a few things such as:
 
 Where are the sequences of the models stored in pymol and how 
 do I retrieve them?
 
 Are these taken from the ATOM or SEQRES sections of the PDB file?
 
 Is there a PDB parser class somewhere for reading in the PDB files?
 
 I had a browse through the pymol directory but couldn't find 
 anything which looked like the above. I'm still very new to 
 python so the chances are I have missed it.
 
 many thanks,
 
 Jules
 
 
 ---
 This SF.net email is sponsored by: IT Product Guide on 
 ITManagersJournal Use IT products in your business? Tell us 
 what you think of them. Give us Your Opinions, Get Free 
 ThinkGeek Gift Certificates! Click to find out more 
 http://productguide.itmanagersjournal.com/guidepromo.tmpl
 ___
 PyMOL-users mailing list
 PyMOL-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/pymol-users
 





Re: [PyMOL] Swissprot

2004-10-18 Thread Filipe Maia


Is there a PDB parser class somewhere for reading in the PDB files?
layer2/ObjectMolecule2.c:ObjectMoleculePDBStr2CoordSet() is probably a  
good place to start.





--
All generalizations are false, including this one.
 -- Mark Twain



Re: [PyMOL] Swissprot

2004-10-18 Thread Charles Moad
I think you want to avoid the c files.  Look at the pdb loader plugin I
wrote:

http://euclid.uits.iupui.edu/~cmoad/pymolPlugins/remote_pdb_load.py

Specifically, one clean way to load a pdb is:

cmd.read_pdbstr(pdbString, label)

There is also a command for loading from a file.

- Charlie

On Mon, 2004-10-18 at 09:03, Filipe Maia wrote:
 
  Is there a PDB parser class somewhere for reading in the PDB files?
 layer2/ObjectMolecule2.c:ObjectMoleculePDBStr2CoordSet() is probably a  
 good place to start.