From: Jason V. <jas...@sc...> - 2012-04-09 12:20:32
|
Hi Osvaldo, Sorry for the delay. Mobile PyMOL development is taking up most of my time now. There is no easy way. You'd need to wrap the save function. It would look something like (warning untested code follows): def my_save(file,object,header): # make sure there's a newline after the header suff = "" if header[-1]=='\n' else '\n' f = open(file, 'wb') # write the header f.write(header+suff) # write the PDB f.write(cmd.get_pdbstr(object)) f.close() You would then call this as: my_save myFile.pdb, myObject, myHeader. Cheers, -- Jason On Thu, Apr 5, 2012 at 1:33 PM, Osvaldo Martin <alo...@gm...> wrote: > Hi, > > There is an easy way to save a pdb adding custom headers using PyMol? > > Thanks. > > ------------------------------------------------------------------------------ > Better than sec? Nothing is better than sec when it comes to > monitoring Big Data applications. Try Boundary one-second > resolution app monitoring today. Free. > http://p.sf.net/sfu/Boundary-dev2dev > _______________________________________________ > PyMOL-users mailing list (PyM...@li...) > Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > Archives: http://www.mail-archive.com/pym...@li... -- Jason Vertrees, PhD PyMOL Product Manager Schrödinger, LLC (e) Jas...@sc... (o) +1 (603) 374-7120 |