From: Z. C. <272...@qq...> - 2016-05-14 11:45:14
|
Dear Dr Tsjerk, Thank you very much!. For example, I have a structure of "protein.pdb". I tried but seems not work: PyMOL>open("ss.dat","w").writelines(["Residue %d: %s\n"%(a.resi,a.ss) for a in cmd.get_model("protein"+" and n. ca").atom]) Traceback (most recent call last): File "D:\Program Files (x86)\PyMOL\PyMOL/modules\pymol\parser.py", line 464, in parse exec(layer.com2+"\n",self.pymol_names,self.pymol_names) File "<string>", line 1, in <module> TypeError: int argument required Can I ask how to modify that? Thank you! ------------------ Original ------------------ From: "Tsjerk Wassenaar";<ts...@gm...>; Date: Sat, May 14, 2016 05:24 AM To: "ZHANG Cheng"<272...@qq...>; Cc: "pymol-users"<pym...@li...>; Subject: Re: [PyMOL] How to export secondary structure information from a PDBusing PyMol? Hi Zhang Cheng, If you replace SELECTION with a proper selection statement (with quotes), then something like: open("ss.dat","w").writelines( ["Residue %d: %s\n"%(a.resi,a.ss) for a in cmd.get_model(SELECTION+" and n. ca").atom] ) It will write the results to a file called ss.dat. Do mind all parentheses/brackets. Hope it helps, Tsjerk On Fri, May 13, 2016 at 10:30 PM, ZHANG Cheng <272...@qq...> wrote: Dear PyMol friends, I would like to export the secondary structure of individual residues from a PDB. Can I ask if I can use PyMol to do that? I would like something like this: Residue 1: alpha-helix Residue 2: beta-sheet ...... I think "http://webclu.bio.wzw.tum.de/cgi-bin/stride/stridecgi.py" can also do that. However, I found that one residue is loop in Pymol but is indicated as "strand" in the website. So I wonder if Pymol can output the secondary structure of individual residues from a PDB? Thank you. ------------------------------------------------------------------------------ Mobile security can be enabling, not merely restricting. Employees who bring their own devices (BYOD) to work are irked by the imposition of MDM restrictions. Mobile Device Manager Plus allows you to control only the apps on BYO-devices by containerizing them, leaving personal data untouched! https://ad.doubleclick.net/ddm/clk/304595813;131938128;j _______________________________________________ PyMOL-users mailing list (PyM...@li...) Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users Archives: http://www.mail-archive.com/pym...@li... -- Tsjerk A. Wassenaar, Ph.D. |