You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(13) |
Nov
(22) |
Dec
(35) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(33) |
Feb
(46) |
Mar
(56) |
Apr
(29) |
May
(56) |
Jun
(30) |
Jul
(64) |
Aug
(54) |
Sep
(86) |
Oct
(106) |
Nov
(50) |
Dec
(67) |
2003 |
Jan
(78) |
Feb
(98) |
Mar
(51) |
Apr
(95) |
May
(53) |
Jun
(103) |
Jul
(93) |
Aug
(64) |
Sep
(87) |
Oct
(93) |
Nov
(78) |
Dec
(86) |
2004 |
Jan
(83) |
Feb
(90) |
Mar
(64) |
Apr
(112) |
May
(103) |
Jun
(57) |
Jul
(101) |
Aug
(84) |
Sep
(92) |
Oct
(96) |
Nov
(86) |
Dec
(32) |
2005 |
Jan
(88) |
Feb
(108) |
Mar
(111) |
Apr
(107) |
May
(120) |
Jun
(134) |
Jul
(143) |
Aug
(129) |
Sep
(75) |
Oct
(171) |
Nov
(125) |
Dec
(65) |
2006 |
Jan
(95) |
Feb
(105) |
Mar
(114) |
Apr
(124) |
May
(87) |
Jun
(66) |
Jul
(88) |
Aug
(65) |
Sep
(71) |
Oct
(92) |
Nov
(94) |
Dec
(60) |
2007 |
Jan
(81) |
Feb
(84) |
Mar
(82) |
Apr
(68) |
May
(58) |
Jun
(80) |
Jul
(30) |
Aug
(47) |
Sep
(68) |
Oct
(92) |
Nov
(59) |
Dec
(17) |
2008 |
Jan
(69) |
Feb
(81) |
Mar
(60) |
Apr
(34) |
May
(47) |
Jun
(65) |
Jul
(46) |
Aug
(49) |
Sep
(84) |
Oct
(43) |
Nov
(33) |
Dec
(30) |
2009 |
Jan
(62) |
Feb
(48) |
Mar
(123) |
Apr
(73) |
May
(72) |
Jun
(69) |
Jul
(78) |
Aug
(72) |
Sep
(99) |
Oct
(82) |
Nov
(70) |
Dec
(53) |
2010 |
Jan
(112) |
Feb
(95) |
Mar
(127) |
Apr
(110) |
May
(135) |
Jun
(91) |
Jul
(91) |
Aug
(79) |
Sep
(136) |
Oct
(63) |
Nov
(38) |
Dec
(64) |
2011 |
Jan
(59) |
Feb
(109) |
Mar
(191) |
Apr
(130) |
May
(94) |
Jun
(90) |
Jul
(89) |
Aug
(127) |
Sep
(135) |
Oct
(113) |
Nov
(136) |
Dec
(140) |
2012 |
Jan
(158) |
Feb
(131) |
Mar
(151) |
Apr
(88) |
May
(121) |
Jun
(85) |
Jul
(82) |
Aug
(56) |
Sep
(55) |
Oct
(125) |
Nov
(87) |
Dec
(65) |
2013 |
Jan
(81) |
Feb
(64) |
Mar
(90) |
Apr
(77) |
May
(80) |
Jun
(92) |
Jul
(92) |
Aug
(70) |
Sep
(69) |
Oct
(60) |
Nov
(99) |
Dec
(50) |
2014 |
Jan
(89) |
Feb
(66) |
Mar
(52) |
Apr
(70) |
May
(68) |
Jun
(44) |
Jul
(68) |
Aug
(81) |
Sep
(152) |
Oct
(106) |
Nov
(74) |
Dec
(57) |
2015 |
Jan
(93) |
Feb
(48) |
Mar
(60) |
Apr
(107) |
May
(82) |
Jun
(64) |
Jul
(74) |
Aug
(38) |
Sep
(49) |
Oct
(99) |
Nov
(105) |
Dec
(51) |
2016 |
Jan
(68) |
Feb
(87) |
Mar
(55) |
Apr
(90) |
May
(68) |
Jun
(25) |
Jul
(25) |
Aug
(41) |
Sep
(35) |
Oct
(55) |
Nov
(24) |
Dec
(26) |
2017 |
Jan
(59) |
Feb
(49) |
Mar
(24) |
Apr
(50) |
May
(45) |
Jun
(63) |
Jul
(36) |
Aug
(26) |
Sep
(22) |
Oct
(23) |
Nov
(26) |
Dec
(29) |
2018 |
Jan
(17) |
Feb
(21) |
Mar
(30) |
Apr
(34) |
May
(24) |
Jun
(47) |
Jul
(65) |
Aug
(30) |
Sep
(24) |
Oct
(52) |
Nov
(21) |
Dec
(17) |
2019 |
Jan
(9) |
Feb
(39) |
Mar
(32) |
Apr
(22) |
May
(30) |
Jun
(69) |
Jul
(40) |
Aug
(48) |
Sep
(17) |
Oct
(26) |
Nov
(30) |
Dec
(19) |
2020 |
Jan
(32) |
Feb
(26) |
Mar
(16) |
Apr
(34) |
May
(50) |
Jun
(87) |
Jul
(51) |
Aug
(23) |
Sep
(25) |
Oct
(48) |
Nov
(32) |
Dec
(6) |
2021 |
Jan
(12) |
Feb
(31) |
Mar
(15) |
Apr
(31) |
May
(13) |
Jun
(13) |
Jul
(24) |
Aug
(9) |
Sep
(11) |
Oct
(28) |
Nov
(26) |
Dec
(25) |
2022 |
Jan
(47) |
Feb
(22) |
Mar
(22) |
Apr
(12) |
May
(4) |
Jun
(26) |
Jul
(17) |
Aug
(2) |
Sep
(13) |
Oct
(6) |
Nov
(13) |
Dec
(4) |
2023 |
Jan
(7) |
Feb
(6) |
Mar
(13) |
Apr
(2) |
May
(25) |
Jun
(13) |
Jul
(12) |
Aug
(10) |
Sep
(5) |
Oct
(13) |
Nov
(19) |
Dec
(7) |
2024 |
Jan
(3) |
Feb
(12) |
Mar
(1) |
Apr
(13) |
May
(11) |
Jun
|
Jul
(20) |
Aug
(4) |
Sep
(4) |
Oct
(5) |
Nov
(4) |
Dec
(6) |
2025 |
Jan
(16) |
Feb
(8) |
Mar
(10) |
Apr
(6) |
May
(13) |
Jun
(7) |
Jul
(4) |
Aug
(1) |
Sep
(2) |
Oct
(1) |
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
1
(3) |
2
(1) |
3
(3) |
4
(2) |
5
(2) |
6
|
7
|
8
(1) |
9
(1) |
10
|
11
(5) |
12
(4) |
13
(2) |
14
|
15
(3) |
16
(10) |
17
(5) |
18
(7) |
19
|
20
(3) |
21
(3) |
22
(13) |
23
(18) |
24
(11) |
25
(14) |
26
(1) |
27
(1) |
28
(1) |
29
(6) |
30
(2) |
31
(5) |
|
|
|
From: Jason V. <jas...@sc...> - 2011-08-31 21:24:39
|
Hi all, This is neat enough that I bet it gets implemented (relatively) soon. If someone would like to, please file this on the open-source tracker. I'll update the case when it's done. Cheers, -- Jason On Wed, Aug 31, 2011 at 11:11 AM, Arne Dieckmann <adi...@go...> wrote: > Hi Shiven, > > thanks a lot, but this is not really what I was looking for. I would like to have a new representation or a script that I can load from within python. Anyway, for some special cases I might have a look at the Blender option. > > > Best, > Arne > > > On Aug 31, 2011, at 7:01 AM, Shivender Shandilya wrote: > >> Hi Arne, >> >> If you are familiar with Blender, you could setup a bump-map or other texture(s) and apply it to any/all atoms. >> >> Here's how you can get your structure into Blender: >> http://pymolwiki.org/index.php/Blender >> >> Good luck! >> >> Best, >> Shiven >> >> >> On Aug 30, 2011, at 5:37 PM, Arne Dieckmann wrote: >> >>> Hi all, >>> >>> I would be interested in creating custom textures for spheres in pymol. More explicitely, I would like to draw two curved lines onto every sphere. Is there any way I can that except placing CGO-objects on every atom? >>> >>> >>> Thanks a lot, >>> Arne >>> >>> >>> ------------------------------------------------------------------------------ >>> Special Offer -- Download ArcSight Logger for FREE! >>> Finally, a world-class log management solution at an even better >>> price-free! And you'll get a free "Love Thy Logs" t-shirt when you >>> download Logger. Secure your free ArcSight Logger TODAY! >>> http://p.sf.net/sfu/arcsisghtdev2dev >>> _______________________________________________ >>> PyMOL-users mailing list (PyM...@li...) >>> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users >>> Archives: http://www.mail-archive.com/pym...@li... >> >> > > > ------------------------------------------------------------------------------ > Special Offer -- Download ArcSight Logger for FREE! > Finally, a world-class log management solution at an even better > price-free! And you'll get a free "Love Thy Logs" t-shirt when you > download Logger. Secure your free ArcSight Logger TODAY! > http://p.sf.net/sfu/arcsisghtdev2dev > _______________________________________________ > 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 Schrodinger, LLC (e) Jas...@sc... (o) +1 (603) 374-7120 |
From: Arne D. <adi...@go...> - 2011-08-31 17:11:47
|
Hi Shiven, thanks a lot, but this is not really what I was looking for. I would like to have a new representation or a script that I can load from within python. Anyway, for some special cases I might have a look at the Blender option. Best, Arne On Aug 31, 2011, at 7:01 AM, Shivender Shandilya wrote: > Hi Arne, > > If you are familiar with Blender, you could setup a bump-map or other texture(s) and apply it to any/all atoms. > > Here's how you can get your structure into Blender: > http://pymolwiki.org/index.php/Blender > > Good luck! > > Best, > Shiven > > > On Aug 30, 2011, at 5:37 PM, Arne Dieckmann wrote: > >> Hi all, >> >> I would be interested in creating custom textures for spheres in pymol. More explicitely, I would like to draw two curved lines onto every sphere. Is there any way I can that except placing CGO-objects on every atom? >> >> >> Thanks a lot, >> Arne >> >> >> ------------------------------------------------------------------------------ >> Special Offer -- Download ArcSight Logger for FREE! >> Finally, a world-class log management solution at an even better >> price-free! And you'll get a free "Love Thy Logs" t-shirt when you >> download Logger. Secure your free ArcSight Logger TODAY! >> http://p.sf.net/sfu/arcsisghtdev2dev >> _______________________________________________ >> PyMOL-users mailing list (PyM...@li...) >> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users >> Archives: http://www.mail-archive.com/pym...@li... > > |
From: Ricardo O. S. S. <ros...@ya...> - 2011-08-31 16:55:09
|
Hello Shiven, thanks for the Blender tip! Cheers! --- Ricardo O. S. Soares , PhD Student. Group of Biological Physics - Department of Physics & Chemistry Faculty of Pharmaceutical Sciences at Ribeirão Preto - University of São Paulo. >________________________________ >De: Shivender Shandilya <shi...@gm...> >Para: Arne Dieckmann <adi...@go...> >Cc: pym...@li... >Enviadas: Quarta-feira, 31 de Agosto de 2011 11:01 >Assunto: Re: [PyMOL] custom textures > >Hi Arne, > >If you are familiar with Blender, you could setup a bump-map or other texture(s) and apply it to any/all atoms. > >Here's how you can get your structure into Blender: >http://pymolwiki.org/index.php/Blender > >Good luck! > >Best, >Shiven > > >On Aug 30, 2011, at 5:37 PM, Arne Dieckmann wrote: > >> Hi all, >> >> I would be interested in creating custom textures for spheres in pymol. More explicitely, I would like to draw two curved lines onto every sphere. Is there any way I can that except placing CGO-objects on every atom? >> >> >> Thanks a lot, >> Arne >> >> >> ------------------------------------------------------------------------------ >> Special Offer -- Download ArcSight Logger for FREE! >> Finally, a world-class log management solution at an even better >> price-free! And you'll get a free "Love Thy Logs" t-shirt when you >> download Logger. Secure your free ArcSight Logger TODAY! >> http://p.sf.net/sfu/arcsisghtdev2dev >> _______________________________________________ >> PyMOL-users mailing list (PyM...@li...) >> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users >> Archives: http://www.mail-archive.com/pym...@li... > > > >------------------------------------------------------------------------------ >Special Offer -- Download ArcSight Logger for FREE! >Finally, a world-class log management solution at an even better >price-free! And you'll get a free "Love Thy Logs" t-shirt when you >download Logger. Secure your free ArcSight Logger TODAY! >http://p.sf.net/sfu/arcsisghtdev2dev >_______________________________________________ >PyMOL-users mailing list (PyM...@li...) >Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users >Archives: http://www.mail-archive.com/pym...@li... > > > |
From: Shivender S. <shi...@gm...> - 2011-08-31 16:01:53
|
Hi Arne, If you are familiar with Blender, you could setup a bump-map or other texture(s) and apply it to any/all atoms. Here's how you can get your structure into Blender: http://pymolwiki.org/index.php/Blender Good luck! Best, Shiven On Aug 30, 2011, at 5:37 PM, Arne Dieckmann wrote: > Hi all, > > I would be interested in creating custom textures for spheres in pymol. More explicitely, I would like to draw two curved lines onto every sphere. Is there any way I can that except placing CGO-objects on every atom? > > > Thanks a lot, > Arne > > > ------------------------------------------------------------------------------ > Special Offer -- Download ArcSight Logger for FREE! > Finally, a world-class log management solution at an even better > price-free! And you'll get a free "Love Thy Logs" t-shirt when you > download Logger. Secure your free ArcSight Logger TODAY! > http://p.sf.net/sfu/arcsisghtdev2dev > _______________________________________________ > PyMOL-users mailing list (PyM...@li...) > Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > Archives: http://www.mail-archive.com/pym...@li... |
From: Tsjerk W. <ts...@gm...> - 2011-08-31 04:30:25
|
Hi Arne, Unfortunately that is not possible. You could export the scene to POV-Ray format and make the modifications there. Cheers, Tsjerk On Tue, Aug 30, 2011 at 11:37 PM, Arne Dieckmann <adi...@go...> wrote: > Hi all, > > I would be interested in creating custom textures for spheres in pymol. More explicitely, I would like to draw two curved lines onto every sphere. Is there any way I can that except placing CGO-objects on every atom? > > > Thanks a lot, > Arne > > > ------------------------------------------------------------------------------ > Special Offer -- Download ArcSight Logger for FREE! > Finally, a world-class log management solution at an even better > price-free! And you'll get a free "Love Thy Logs" t-shirt when you > download Logger. Secure your free ArcSight Logger TODAY! > http://p.sf.net/sfu/arcsisghtdev2dev > _______________________________________________ > 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. post-doctoral researcher Molecular Dynamics Group * Groningen Institute for Biomolecular Research and Biotechnology * Zernike Institute for Advanced Materials University of Groningen The Netherlands |
From: Arne D. <adi...@go...> - 2011-08-30 21:38:01
|
Hi all, I would be interested in creating custom textures for spheres in pymol. More explicitely, I would like to draw two curved lines onto every sphere. Is there any way I can that except placing CGO-objects on every atom? Thanks a lot, Arne |
From: Troels E. L. <tl...@gm...> - 2011-08-30 11:02:00
|
Hi PyMOLers. I was tired, not to be able to load a dye molecule, and put it next to my protein with full control. Especially, I needed to be able to rotate my dye molecule around a line, which is not supported in PyMOL. So I investigated the PyMOL TTT matrixes, and made some handy scripts. Check the scripts kit out: rotkit.py <" rel="nofollow">http://pymolwiki.org/index.php/Rotkit> I have made there a little tutorial to take one through the functions. *Available in PyMOL* - rotateline(Pos1,Pos2,degangle,molecule): "Pos1->Pos2" define a line whereabout "molecule" will be rotated "degangle" degrees *rotateline Pos1=P513C_CA, Pos2=P513C_CB, degangle=5, molecule=Atto590* *rotateline Pos1=dyeatom87, Pos2=dyeatom85, degangle=10, molecule=Atto590* - mutate(molecule,chain,resi,target="CYS",mutframe="1"): Mutate a /molecule//chain/resi into a target, and selecting most probable frame 1 *mutate 1HP1, chain=A, resi=515, target=CYS, mutframe=1* - toline(Pos1,Pos2,atom,molecule,dist=1): Translate molecule atom, 1 angstrom away in the same direction Pos1->Pos2 specify *toline Pos1=P513C_CA, Pos2=P513C_CB, atom=dyeatom87, molecule=Atto590, dist=3* *Available through PyMOL mini shell* - printMat(matrix): prints the TTT matrix in a readable format. (4X4) - getxyz(Sel): output is a list [x,y,z] in float. The input can be a list, a string(list) or a selection. - vector(Sel1,Sel2): Finds the vector between points. Gets the xyz list from getxyz, so input can be anything. - vectorstr(vector): turn a vector in list format into string. No real function actually. - transmat(vector,dist=1): Makes a TTT translation matrix for according to the input vector. The vector is multiplied with dist. - unitvector(vector): Make a vector a unitvector. - radangle(angle): Convert degree to radians. Not that all input are assumed to be in degrees, and are converted automatically. - rotmat(angle,vectornorm,pointcoord): This function is the most important. That makes the TTT matrix that rotates a molecule around a normalized vector, which goes through a coordinate point. - crossprod(Vector1, Vector2): Makes a crossproduct between two vectors - crosspoint(Pos1, crossprod): Returns the endpoint for the Position plus the crossproduct vector. Suitable if one would like to rotate around a crossvector. Best Troels Emtekær Linnet |
From: Suda R. <bio...@gm...> - 2011-08-29 13:16:12
|
Dear All, Thanks a lot for your help. I am able to do now :-) Cheers, -Suda |
From: Martin H. <ma...@bl...> - 2011-08-29 09:54:32
|
Try this. import subprocess # propkaprocess # shell=False controls that the process remains in the same thread. propkap = Popen(['propka'], stdin=open('1pdb.pdb', 'r') stdout=subprocess.PIPE stderr=subprocess.PIPE shell=False) propkap.stdout.read() Martin Hediger On 28.08.11 19:24, Troels Emtekær Linnet wrote: > Thanks Jason. But still no luck... > > So, I changed it to a python script. It was important that the ending > of the file is .py :-) > But, I can see from the list of objects, that PyMOL fetches the next > protein before it has finished propka first. > Does pymol run external script in some kind of asynchron mode as default? > > --------------------------------- > import pymol > from pymol import cmd > import os > os.chdir("/homes/linnet/Documents/Speciale/5NT-project/Mutant-construct/predict_reactivity/Comparison/Match") > > cmd.cartoon("auto") > cmd.set("cartoon_fancy_helices","1") > cmd.bg_color("white") > cmd.set("fog","0") > cmd.set("cartoon_transparency","0.7") > cmd.set("auto_zoom","off") > > import propka > #resis = > [["1bj6","36"],["1bj6","39"],["1bj6","49"],["1ag1","14"],["1gu9","133"],["1gu9","130"],["1omu","56"],["1khg","273"],["2trx","35"], > #["1tde","32"],["1tde","35"],["2ovo","56"],["1m8b","56"],["1hic","39"],["1m8c","56"],["1ppo","25"],["1qlp","232"]] > resis = [["1ppo","25"],["1qlp","232"]] > i = 0 > results = [] > for p,r in resis: > cmd.fetch(p,async="0") > cmd.refresh() > # When we import a module in python, the namespace is normally: > module.function > # And we see, that propka expect resi to be in "str" format. > # And we don't want the logtime function > pkavalues = propka.propka(molecule=p,resi=r,resn="CYS",logtime=i) > results.append(pkavalues) > cmd.refresh() > i = i + 1 > cmd.zoom("all") > print results[0] > print results[1] > > > > 2011/8/28 Jason Vertrees <jas...@sc... > <mailto:jas...@sc...>> > > Hi Troels, > > In PyMOL, it you try the following, what happens for you? > > # make this a file called chill.py > import time > def chill(): > rightThisSecond = time.time() > i = 0 > while time.time() < rightThisSecond + 3.0: > i+=1 > print "The farthest I could count in 3 seconds was %d." % i > > # make this a file called troels.py > import pymol > from pymol import cmd > import chill > resis = [ ["1bj6","36"], ["1bj6","39"], ["1bj6","49"], > ["1ag1","14"], > ["1gu9","133"], ["1gu9","130"], ] > for p,r in resis: > # fetch a protein > cmd.fetch(p,async=0) > print "-- Fetched %s" % p > # do something slow > chill.chill() > # some post processing > print "%s has %d atoms" % (p, cmd.count_atoms(p)) > print "%s/%s has %d atoms" % (p, r, cmd.count_atoms("%s and i. > %s" % (p,r))) > cmd.delete(p) > print "-- Deleted protien" > > > Now load PyMOL and try, > > run ~/troels.py > > Does PyMOL wait for the chill calls to finish? The idea is, wrap your > call in a module/file and import it. Then, call through that function. > > It's about 3 AM my time and I'm sure there's a better solution--but > this might work for now. > > Cheers, > > -- Jason > > > > > 2011/8/26 Troels Emtekær Linnet <tl...@gm... > <mailto:tl...@gm...>>: > > Well, I cant get it to work. > > Pymol speeds ahead of calling propka.propka > > > > Can you give an example of subprocess? > > --------------------------- > > > > import propka > > > > python > > resis = [["1bj6","36"],["1bj6","39"]] > > #resis = > > > [["1bj6","36"],["1bj6","39"],["1bj6","49"],["1ag1","14"],["1gu9","133"],["1gu9","130"],["1omu","56"],["1khg","273"],["2trx","35"], > > > #["1tde","32"],["1tde","35"],["2ovo","56"],["1m8b","56"],["1hic","39"],["1m8c","56"]] > > i = 0 > > for resi in resis: > > cmd.fetch(resi[0],async="0") > > cmd.refresh() > > # When we import a module in python, the namespace is normally: > > module.function > > # And we see, that propka expect resi to be in "str" format. > > # And we don't want the logtime function > > propka.propka(molecule=resi[0],resi=resi[1],logtime=i) > > cmd.refresh() > > i = i + 1 > > python end > > zoom all > > > > > >> hth > >> Martin > >> > >> On 23.08.11 10:48, Troels Emtekær Linnet wrote: > >> > >> Hi. > >> > >> If one writes a pymol script, and calls an external function, > the pymol > >> script continues its operation before waiting for the "success" > of the > >> external function. > >> > >> Is it possible to give a keyword, so it "waits" for the > external function > >> before preceding? > >> > >> Kind of the same function with: > >> fetch 1hp1, async=0 > >> > >> Best > >> Troels > >> > >> > >> > ------------------------------------------------------------------------------ > >> Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > >> user administration capabilities and model configuration. Take > >> the hassle out of deploying and managing Subversion and the > >> tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > >> > >> _______________________________________________ > >> PyMOL-users mailing list (PyM...@li... > <mailto:PyM...@li...>) > >> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > >> Archives: > http://www.mail-archive.com/pym...@li... > >> > >> > >> > ------------------------------------------------------------------------------ > >> Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > >> user administration capabilities and model configuration. Take > >> the hassle out of deploying and managing Subversion and the > >> tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > >> > >> _______________________________________________ > >> PyMOL-users mailing list (PyM...@li... > <mailto:PyM...@li...>) > >> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > >> Archives: > http://www.mail-archive.com/pym...@li... > > > > > > > ------------------------------------------------------------------------------ > > EMC VNX: the world's simplest storage, starting under $10K > > The only unified storage solution that offers unified management > > Up to 160% more powerful than alternatives and 25% more efficient. > > Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev > > _______________________________________________ > > PyMOL-users mailing list (PyM...@li... > <mailto: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 > Schrodinger, LLC > > (e) Jas...@sc... > <mailto:Jas...@sc...> > (o) +1 (603) 374-7120 <tel:%2B1%20%28603%29%20374-7120> > > > > > ------------------------------------------------------------------------------ > EMC VNX: the world's simplest storage, starting under $10K > The only unified storage solution that offers unified management > Up to 160% more powerful than alternatives and 25% more efficient. > Guaranteed. http://p.sf.net/sfu/emc-vnx-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... |
From: zjxu <zj...@ma...> - 2011-08-29 08:14:53
|
Dear Suda, cealign can be used to do structure based superposition PyMOL> cealign target, mobile However, it's a pair-wise based alignment. You have to align two structures each time. Hope this helps. Zhijian Xu Suda Ravindran wrote: > Hi, > > I would like to know how to do structure based superposition using > PyMol for 3 or more structures. Please help me out. > > Thanks, > > -Suda > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > EMC VNX: the world's simplest storage, starting under $10K > The only unified storage solution that offers unified management > Up to 160% more powerful than alternatives and 25% more efficient. > Guaranteed. http://p.sf.net/sfu/emc-vnx-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... |
From: Thomas H. <sp...@us...> - 2011-08-29 07:37:20
|
Hi Suda and Tsjerk, there is "alignto" which used cealign. There is also in the menu "Action > align > all to this" which uses cmd.util.mass_align (and that uses cmd.align). On Robert Campbell's site there is the "align_all.py" script: http://pldserver1.biochem.queensu.ca/~rlc/work/pymol/ On my PyMOLWiki user page there is a "extra_fit" script. http://pymolwiki.org/index.php/User:Speleo3 All those align to a reference object (or state, in case of intra_fit) instead of an all-against-all best fit. Cheers, Thomas On 08/29/2011 08:52 AM, Tsjerk Wassenaar wrote: > Hi Suda, > > Do you mean different structures of the same molecule or different > molecules? For a multistate object, there is intra_fit. for selections > comprising multiple objects it's not currently possible. But it's > being worked on. > > Cheers, > > Tsjerk > > On Mon, Aug 29, 2011 at 8:43 AM, Suda Ravindran<bio...@gm...> wrote: >> Hi, >> >> I would like to know how to do structure based superposition using PyMol for >> 3 or more structures. Please help me out. >> >> Thanks, >> >> -Suda -- Thomas Holder MPI for Developmental Biology |
From: Tsjerk W. <ts...@gm...> - 2011-08-29 06:52:56
|
Hi Suda, Do you mean different structures of the same molecule or different molecules? For a multistate object, there is intra_fit. for selections comprising multiple objects it's not currently possible. But it's being worked on. Cheers, Tsjerk On Mon, Aug 29, 2011 at 8:43 AM, Suda Ravindran <bio...@gm...> wrote: > Hi, > > I would like to know how to do structure based superposition using PyMol for > 3 or more structures. Please help me out. > > Thanks, > > -Suda > > ------------------------------------------------------------------------------ > EMC VNX: the world's simplest storage, starting under $10K > The only unified storage solution that offers unified management > Up to 160% more powerful than alternatives and 25% more efficient. > Guaranteed. http://p.sf.net/sfu/emc-vnx-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... > -- Tsjerk A. Wassenaar, Ph.D. post-doctoral researcher Molecular Dynamics Group * Groningen Institute for Biomolecular Research and Biotechnology * Zernike Institute for Advanced Materials University of Groningen The Netherlands |
From: Suda R. <bio...@gm...> - 2011-08-29 06:43:11
|
Hi, I would like to know how to do structure based superposition using PyMol for 3 or more structures. Please help me out. Thanks, -Suda |
From: Troels E. L. <tl...@gm...> - 2011-08-28 17:24:36
|
Thanks Jason. But still no luck... So, I changed it to a python script. It was important that the ending of the file is .py :-) But, I can see from the list of objects, that PyMOL fetches the next protein before it has finished propka first. Does pymol run external script in some kind of asynchron mode as default? --------------------------------- import pymol from pymol import cmd import os os.chdir("/homes/linnet/Documents/Speciale/5NT-project/Mutant-construct/predict_reactivity/Comparison/Match") cmd.cartoon("auto") cmd.set("cartoon_fancy_helices","1") cmd.bg_color("white") cmd.set("fog","0") cmd.set("cartoon_transparency","0.7") cmd.set("auto_zoom","off") import propka #resis = [["1bj6","36"],["1bj6","39"],["1bj6","49"],["1ag1","14"],["1gu9","133"],["1gu9","130"],["1omu","56"],["1khg","273"],["2trx","35"], #["1tde","32"],["1tde","35"],["2ovo","56"],["1m8b","56"],["1hic","39"],["1m8c","56"],["1ppo","25"],["1qlp","232"]] resis = [["1ppo","25"],["1qlp","232"]] i = 0 results = [] for p,r in resis: cmd.fetch(p,async="0") cmd.refresh() # When we import a module in python, the namespace is normally: module.function # And we see, that propka expect resi to be in "str" format. # And we don't want the logtime function pkavalues = propka.propka(molecule=p,resi=r,resn="CYS",logtime=i) results.append(pkavalues) cmd.refresh() i = i + 1 cmd.zoom("all") print results[0] print results[1] 2011/8/28 Jason Vertrees <jas...@sc...> > Hi Troels, > > In PyMOL, it you try the following, what happens for you? > > # make this a file called chill.py > import time > def chill(): > rightThisSecond = time.time() > i = 0 > while time.time() < rightThisSecond + 3.0: > i+=1 > print "The farthest I could count in 3 seconds was %d." % i > > # make this a file called troels.py > import pymol > from pymol import cmd > import chill > resis = [ ["1bj6","36"], ["1bj6","39"], ["1bj6","49"], > ["1ag1","14"], > ["1gu9","133"], ["1gu9","130"], ] > for p,r in resis: > # fetch a protein > cmd.fetch(p,async=0) > print "-- Fetched %s" % p > # do something slow > chill.chill() > # some post processing > print "%s has %d atoms" % (p, cmd.count_atoms(p)) > print "%s/%s has %d atoms" % (p, r, cmd.count_atoms("%s and i. %s" % > (p,r))) > cmd.delete(p) > print "-- Deleted protien" > > > Now load PyMOL and try, > > run ~/troels.py > > Does PyMOL wait for the chill calls to finish? The idea is, wrap your > call in a module/file and import it. Then, call through that function. > > It's about 3 AM my time and I'm sure there's a better solution--but > this might work for now. > > Cheers, > > -- Jason > > > > > 2011/8/26 Troels Emtekær Linnet <tl...@gm...>: > > Well, I cant get it to work. > > Pymol speeds ahead of calling propka.propka > > > > Can you give an example of subprocess? > > --------------------------- > > > > import propka > > > > python > > resis = [["1bj6","36"],["1bj6","39"]] > > #resis = > > > [["1bj6","36"],["1bj6","39"],["1bj6","49"],["1ag1","14"],["1gu9","133"],["1gu9","130"],["1omu","56"],["1khg","273"],["2trx","35"], > > > #["1tde","32"],["1tde","35"],["2ovo","56"],["1m8b","56"],["1hic","39"],["1m8c","56"]] > > i = 0 > > for resi in resis: > > cmd.fetch(resi[0],async="0") > > cmd.refresh() > > # When we import a module in python, the namespace is normally: > > module.function > > # And we see, that propka expect resi to be in "str" format. > > # And we don't want the logtime function > > propka.propka(molecule=resi[0],resi=resi[1],logtime=i) > > cmd.refresh() > > i = i + 1 > > python end > > zoom all > > > > > >> hth > >> Martin > >> > >> On 23.08.11 10:48, Troels Emtekær Linnet wrote: > >> > >> Hi. > >> > >> If one writes a pymol script, and calls an external function, the pymol > >> script continues its operation before waiting for the "success" of the > >> external function. > >> > >> Is it possible to give a keyword, so it "waits" for the external > function > >> before preceding? > >> > >> Kind of the same function with: > >> fetch 1hp1, async=0 > >> > >> Best > >> Troels > >> > >> > >> > ------------------------------------------------------------------------------ > >> Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > >> user administration capabilities and model configuration. Take > >> the hassle out of deploying and managing Subversion and the > >> tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > >> > >> _______________________________________________ > >> PyMOL-users mailing list (PyM...@li...) > >> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > >> Archives: http://www.mail-archive.com/pym...@li... > >> > >> > >> > ------------------------------------------------------------------------------ > >> Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > >> user administration capabilities and model configuration. Take > >> the hassle out of deploying and managing Subversion and the > >> tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > >> > >> _______________________________________________ > >> PyMOL-users mailing list (PyM...@li...) > >> Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > >> Archives: http://www.mail-archive.com/pym...@li... > > > > > > > ------------------------------------------------------------------------------ > > EMC VNX: the world's simplest storage, starting under $10K > > The only unified storage solution that offers unified management > > Up to 160% more powerful than alternatives and 25% more efficient. > > Guaranteed. http://p.sf.net/sfu/emc-vnx-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 > Schrodinger, LLC > > (e) Jas...@sc... > (o) +1 (603) 374-7120 > |
From: Jason V. <jas...@sc...> - 2011-08-27 16:46:17
|
Hi all, I will be demoing PyMOL at the Schrödinger booth at the Denver ACS. Please feel free to dop ini, check out the new features, and get help if needed. Cheers, -- Jason -- Jason Vertrees, PhD PyMOL Product Manager Schrodinger, LLC (e) Jas...@sc... (o) +1 (603) 374-7120 |
From: Troels E. L. <tl...@gm...> - 2011-08-26 12:00:08
|
Well, I cant get it to work. Pymol speeds ahead of calling propka.propka Can you give an example of subprocess? --------------------------- import propka python resis = [["1bj6","36"],["1bj6","39"]] #resis = [["1bj6","36"],["1bj6","39"],["1bj6","49"],["1ag1","14"],["1gu9","133"],["1gu9","130"],["1omu","56"],["1khg","273"],["2trx","35"], #["1tde","32"],["1tde","35"],["2ovo","56"],["1m8b","56"],["1hic","39"],["1m8c","56"]] i = 0 for resi in resis: cmd.fetch(resi[0],async="0") cmd.refresh() # When we import a module in python, the namespace is normally: module.function # And we see, that propka expect resi to be in "str" format. # And we don't want the logtime function propka.propka(molecule=resi[0],resi=resi[1],logtime=i) cmd.refresh() i = i + 1 python end zoom all hth > Martin > > > On 23.08.11 10:48, Troels Emtekær Linnet wrote: > > Hi. > > If one writes a pymol script, and calls an external function, the pymol > script continues its operation before waiting for the "success" of the > external function. > > Is it possible to give a keyword, so it "waits" for the external function > before preceding? > > Kind of the same function with: > fetch 1hp1, async=0 > > Best > Troels > > > ------------------------------------------------------------------------------ > Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > user administration capabilities and model configuration. Take > the hassle out of deploying and managing Subversion and the > tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > > > _______________________________________________ > PyMOL-users mailing list (PyM...@li...) > Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > Archives: http://www.mail-archive.com/pym...@li... > > > > ------------------------------------------------------------------------------ > Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > user administration capabilities and model configuration. Take > the hassle out of deploying and managing Subversion and the > tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > > _______________________________________________ > PyMOL-users mailing list (PyM...@li...) > Info Page: https://lists.sourceforge.net/lists/listinfo/pymol-users > Archives: http://www.mail-archive.com/pym...@li... > |
From: H. A. S. <ad...@st...> - 2011-08-25 16:59:16
|
Thanks Tsjerk, When I run this script, I see: PyMOL>pplanes selection, (sele) Selector-Error: Invalid Selection Name. ( selection and n. ca )<-- I have tried selecting just one "n and ca" in the pdb, tried selecting multiple "n and ca", tried a bunch of other selections, but it's not working. What am I supposed to be selecting in the pdb to make the script work? On Aug 25, 2011, at 11:28 AM, Tsjerk Wassenaar wrote: > Hi Adam, > > Here's an alternative script... The command is pplanes (peptide-planes): > > run triangles.py > pplanes selection[, color[, alpha[, state[, name]]]] > > Hope it helps, > > Tsjerk > > > On Thu, Aug 25, 2011 at 5:34 PM, H. Adam Steinberg <ad...@st...> wrote: >> Hi all, >> Can anyone help me with a problem that I am having trying to run a python >> script? >> I am trying to run the bbPlane script from the PyMOLWiki >> <" rel="nofollow">http://www.pymolwiki.org/index.php/BbPlane> >> I have copied the script from the web page, to a plain text document, saved >> it as "bbPlane.py" but when I run it I get: >> ------------ >> PyMOL>run bbPlane.py >> Traceback (most recent call last): >> File "/Volumes/Port >> 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 332, in parse >> File "/Volumes/Port >> 3/software/MacPyMOL.app/pymol/modules/pymol/parsing.py", line 455, in >> run_file >> File "bbPlane.py", line 14 >> >> ^ >> SyntaxError: invalid syntax >> ------------- >> script is here: >> >> # >> # -- bbPlane.py - draws a CGO plane across the backbone atoms of >> # neighboring amino acids >> # >> # Author: Jason Vertrees, 06/2010 >> # Modified by Thomas Holder, 06/2010 >> # Modified by Blaine Bell, 08/2011 >> # Copyright (C) Schrodinger >> # Open Source License: MIT >> # >> from pymol.cgo import * # get constants >> from pymol import cmd, stored >> from chempy import cpv >> >> def bbPlane(objSel='(all)', color='white', transp=0.0): >> """ >> DESCRIPTION >> >> Draws a plane across the backbone for a selection >> >> ARGUMENTS >> >> objSel = string: protein object or selection {default: (all)} >> >> color = string: color name or number {default: white} >> >> transp = float: transparency component (0.0--1.0) {default: 0.0} >> >> NOTES >> >> You need to pass in an object or selection with at least two >> amino acids. The plane spans CA_i, O_i, N-H_(i+1), and CA_(i+1) >> """ >> # format input >> transp = float(transp) >> stored.AAs = [] >> coords = dict() >> >> # need hydrogens on peptide nitrogen >> cmd.h_add('(%s) and n. N' % objSel) >> >> # get the list of residue ids >> for obj in cmd.get_object_list(objSel): >> sel = obj + " and (" + objSel + ")" >> for a in cmd.get_model(sel + " and n. CA").atom: >> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >> stored.AAs.append(key) >> coords[key] = [a.coord,None,None] >> for a in cmd.get_model(sel + " and n. O").atom: >> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >> if key in coords: >> coords[key][1] = a.coord >> for a in cmd.get_model("(hydro or n. CD) and nbr. (" + sel + " and >> n. N)").atom: >> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >> if key in coords: >> coords[key][2] = a.coord >> >> # need at least two amino acids >> if len(stored.AAs) <= 1: >> print "ERROR: Please provide at least two amino acids, the >> alpha-carbon on the 2nd is needed." >> return >> >> # prepare the cgo >> obj = [ >> BEGIN, TRIANGLES, >> COLOR, >> ] >> obj.extend(cmd.get_color_tuple(color)) >> >> for res in range(0, len(stored.AAs)-1): >> curIdx, nextIdx = str(stored.AAs[res]), str(stored.AAs[res+1]) >> >> # populate the position array >> pos = [coords[curIdx][0], coords[curIdx][1], coords[nextIdx][2], >> coords[nextIdx][0]] >> >> # if the data are incomplete for any residues, ignore >> if None in pos: >> print 'peptide bond %s -> %s incomplete' % (curIdx, nextIdx) >> continue >> >> if cpv.distance(pos[0], pos[3]) > 4.0: >> print '%s and %s not adjacent' % (curIdx, nextIdx) >> continue >> >> # need to order vertices to generate correct triangles for plane >> # modified/added by B.Bell 8/18/2011 >> sumpos = cpv.add(pos[0], cpv.add(pos[1], cpv.add(pos[2], pos[3]))) >> centerpos = [ sumpos[0]/4., sumpos[1]/4., sumpos[2]/4. ] >> angles = [ [ 0., 0 ] ] >> s00 = cpv.sub(pos[0], centerpos) >> for i in range(1,4): >> s = cpv.sub(pos[i], centerpos) >> ang = cpv.get_angle(s00, s) >> angles.append( [ ang, i] ) >> def sortfirst(a, b): >> return cmp(a[0], b[0]) >> angles.sort(sortfirst) >> verts = map(lambda x: x[1], angles) >> vorder = [ verts[0], verts[1], verts[2], >> verts[1], verts[3], verts[2] ] >> # fill in the vertex data for the triangles; >> for i in vorder: >> obj.append(VERTEX) >> obj.extend(pos[i]) >> >> # finish the CGO >> obj.append(END) >> >> # update the UI >> newName = cmd.get_unused_name("backbonePlane") >> cmd.load_cgo(obj, newName) >> cmd.set("cgo_transparency", transp, newName) >> >> >> cmd.extend("bbPlane", bbPlane) >> >> artforscience >> H. Adam Steinberg >> Artist, Scientist, Developmental Editor >> www.artforscience.com >> 7904 Bowman Rd >> Lodi, WI 53555 >> 608/729-5944 >> >> ------------------------------------------------------------------------------ >> EMC VNX: the world's simplest storage, starting under $10K >> The only unified storage solution that offers unified management >> Up to 160% more powerful than alternatives and 25% more efficient. >> Guaranteed. http://p.sf.net/sfu/emc-vnx-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... >> > > > > -- > Tsjerk A. Wassenaar, Ph.D. > > post-doctoral researcher > Molecular Dynamics Group > * Groningen Institute for Biomolecular Research and Biotechnology > * Zernike Institute for Advanced Materials > University of Groningen > The Netherlands > <triangles.py> H. Adam Steinberg 7904 Bowman Rd Lodi, WI 53555 608/592-2366 |
From: Jason V. <jas...@sc...> - 2011-08-25 16:47:48
|
Hi Adam, I updated the wiki page to remove the spurious spaces--good idea. > I am trying to follow the example in the Wiki to make sure it works before I try it on my pdb. However, when I run the command "bbPlane i. 4-10" I get a new error: > > PyMOL>bbPlane i. 4-10 > Traceback (most recent call last): > File "/Volumes/Port 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 250, in parse > File "bbPlane.py", line 110, in bbPlane > newName = cmd.get_unused_name("backbonePlane") > AttributeError: 'module' object has no attribute 'get_unused_name' This sounds like you need to update your version of PyMOL. What version are you using? Cheers, -- Jason On Thu, Aug 25, 2011 at 12:41 PM, H. Adam Steinberg <ad...@st...> wrote: > I erased all of the spaces in the "blank" lines and now the script works. When I erased them in line 14 then it found them in kine 38, etc. You may want to update the script on the WIki to one without spaces. > > I am trying to follow the example in the Wiki to make sure it works before I try it on my pdb. However, when I run the command "bbPlane i. 4-10" I get a new error: > > PyMOL>bbPlane i. 4-10 > Traceback (most recent call last): > File "/Volumes/Port 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 250, in parse > File "bbPlane.py", line 110, in bbPlane > newName = cmd.get_unused_name("backbonePlane") > AttributeError: 'module' object has no attribute 'get_unused_name' > > On Aug 25, 2011, at 11:09 AM, Jason Vertrees wrote: > >> Hi Adam, >> >> I just copy/pasted the script you attached in your email and it worked >> fine. There are, however two spaces on line 14--maybe the parser >> thinks it found a block indent? Try erasing line 14 (the line >> following "from chempy import cpv") and re-running the script. >> >> Cheers, >> >> -- Jason >> >> On Thu, Aug 25, 2011 at 11:34 AM, H. Adam Steinberg <ad...@st...> wrote: >>> Hi all, >>> Can anyone help me with a problem that I am having trying to run a python >>> script? >>> I am trying to run the bbPlane script from the PyMOLWiki >>> <" rel="nofollow">http://www.pymolwiki.org/index.php/BbPlane> >>> I have copied the script from the web page, to a plain text document, saved >>> it as "bbPlane.py" but when I run it I get: >>> ------------ >>> PyMOL>run bbPlane.py >>> Traceback (most recent call last): >>> File "/Volumes/Port >>> 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 332, in parse >>> File "/Volumes/Port >>> 3/software/MacPyMOL.app/pymol/modules/pymol/parsing.py", line 455, in >>> run_file >>> File "bbPlane.py", line 14 >>> >>> ^ >>> SyntaxError: invalid syntax >>> ------------- >>> script is here: >>> >>> # >>> # -- bbPlane.py - draws a CGO plane across the backbone atoms of >>> # neighboring amino acids >>> # >>> # Author: Jason Vertrees, 06/2010 >>> # Modified by Thomas Holder, 06/2010 >>> # Modified by Blaine Bell, 08/2011 >>> # Copyright (C) Schrodinger >>> # Open Source License: MIT >>> # >>> from pymol.cgo import * # get constants >>> from pymol import cmd, stored >>> from chempy import cpv >>> >>> def bbPlane(objSel='(all)', color='white', transp=0.0): >>> """ >>> DESCRIPTION >>> >>> Draws a plane across the backbone for a selection >>> >>> ARGUMENTS >>> >>> objSel = string: protein object or selection {default: (all)} >>> >>> color = string: color name or number {default: white} >>> >>> transp = float: transparency component (0.0--1.0) {default: 0.0} >>> >>> NOTES >>> >>> You need to pass in an object or selection with at least two >>> amino acids. The plane spans CA_i, O_i, N-H_(i+1), and CA_(i+1) >>> """ >>> # format input >>> transp = float(transp) >>> stored.AAs = [] >>> coords = dict() >>> >>> # need hydrogens on peptide nitrogen >>> cmd.h_add('(%s) and n. N' % objSel) >>> >>> # get the list of residue ids >>> for obj in cmd.get_object_list(objSel): >>> sel = obj + " and (" + objSel + ")" >>> for a in cmd.get_model(sel + " and n. CA").atom: >>> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >>> stored.AAs.append(key) >>> coords[key] = [a.coord,None,None] >>> for a in cmd.get_model(sel + " and n. O").atom: >>> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >>> if key in coords: >>> coords[key][1] = a.coord >>> for a in cmd.get_model("(hydro or n. CD) and nbr. (" + sel + " and >>> n. N)").atom: >>> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >>> if key in coords: >>> coords[key][2] = a.coord >>> >>> # need at least two amino acids >>> if len(stored.AAs) <= 1: >>> print "ERROR: Please provide at least two amino acids, the >>> alpha-carbon on the 2nd is needed." >>> return >>> >>> # prepare the cgo >>> obj = [ >>> BEGIN, TRIANGLES, >>> COLOR, >>> ] >>> obj.extend(cmd.get_color_tuple(color)) >>> >>> for res in range(0, len(stored.AAs)-1): >>> curIdx, nextIdx = str(stored.AAs[res]), str(stored.AAs[res+1]) >>> >>> # populate the position array >>> pos = [coords[curIdx][0], coords[curIdx][1], coords[nextIdx][2], >>> coords[nextIdx][0]] >>> >>> # if the data are incomplete for any residues, ignore >>> if None in pos: >>> print 'peptide bond %s -> %s incomplete' % (curIdx, nextIdx) >>> continue >>> >>> if cpv.distance(pos[0], pos[3]) > 4.0: >>> print '%s and %s not adjacent' % (curIdx, nextIdx) >>> continue >>> >>> # need to order vertices to generate correct triangles for plane >>> # modified/added by B.Bell 8/18/2011 >>> sumpos = cpv.add(pos[0], cpv.add(pos[1], cpv.add(pos[2], pos[3]))) >>> centerpos = [ sumpos[0]/4., sumpos[1]/4., sumpos[2]/4. ] >>> angles = [ [ 0., 0 ] ] >>> s00 = cpv.sub(pos[0], centerpos) >>> for i in range(1,4): >>> s = cpv.sub(pos[i], centerpos) >>> ang = cpv.get_angle(s00, s) >>> angles.append( [ ang, i] ) >>> def sortfirst(a, b): >>> return cmp(a[0], b[0]) >>> angles.sort(sortfirst) >>> verts = map(lambda x: x[1], angles) >>> vorder = [ verts[0], verts[1], verts[2], >>> verts[1], verts[3], verts[2] ] >>> # fill in the vertex data for the triangles; >>> for i in vorder: >>> obj.append(VERTEX) >>> obj.extend(pos[i]) >>> >>> # finish the CGO >>> obj.append(END) >>> >>> # update the UI >>> newName = cmd.get_unused_name("backbonePlane") >>> cmd.load_cgo(obj, newName) >>> cmd.set("cgo_transparency", transp, newName) >>> >>> >>> cmd.extend("bbPlane", bbPlane) >>> >>> artforscience >>> H. Adam Steinberg >>> Artist, Scientist, Developmental Editor >>> www.artforscience.com >>> 7904 Bowman Rd >>> Lodi, WI 53555 >>> 608/729-5944 >>> >>> ------------------------------------------------------------------------------ >>> EMC VNX: the world's simplest storage, starting under $10K >>> The only unified storage solution that offers unified management >>> Up to 160% more powerful than alternatives and 25% more efficient. >>> Guaranteed. http://p.sf.net/sfu/emc-vnx-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 >> Schrodinger, LLC >> >> (e) Jas...@sc... >> (o) +1 (603) 374-7120 > > H. Adam Steinberg > 7904 Bowman Rd > Lodi, WI 53555 > 608/592-2366 > > -- Jason Vertrees, PhD PyMOL Product Manager Schrodinger, LLC (e) Jas...@sc... (o) +1 (603) 374-7120 |
From: H. A. S. <ad...@st...> - 2011-08-25 16:42:01
|
I erased all of the spaces in the "blank" lines and now the script works. When I erased them in line 14 then it found them in kine 38, etc. You may want to update the script on the WIki to one without spaces. I am trying to follow the example in the Wiki to make sure it works before I try it on my pdb. However, when I run the command "bbPlane i. 4-10" I get a new error: PyMOL>bbPlane i. 4-10 Traceback (most recent call last): File "/Volumes/Port 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 250, in parse File "bbPlane.py", line 110, in bbPlane newName = cmd.get_unused_name("backbonePlane") AttributeError: 'module' object has no attribute 'get_unused_name' On Aug 25, 2011, at 11:09 AM, Jason Vertrees wrote: > Hi Adam, > > I just copy/pasted the script you attached in your email and it worked > fine. There are, however two spaces on line 14--maybe the parser > thinks it found a block indent? Try erasing line 14 (the line > following "from chempy import cpv") and re-running the script. > > Cheers, > > -- Jason > > On Thu, Aug 25, 2011 at 11:34 AM, H. Adam Steinberg <ad...@st...> wrote: >> Hi all, >> Can anyone help me with a problem that I am having trying to run a python >> script? >> I am trying to run the bbPlane script from the PyMOLWiki >> <" rel="nofollow">http://www.pymolwiki.org/index.php/BbPlane> >> I have copied the script from the web page, to a plain text document, saved >> it as "bbPlane.py" but when I run it I get: >> ------------ >> PyMOL>run bbPlane.py >> Traceback (most recent call last): >> File "/Volumes/Port >> 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 332, in parse >> File "/Volumes/Port >> 3/software/MacPyMOL.app/pymol/modules/pymol/parsing.py", line 455, in >> run_file >> File "bbPlane.py", line 14 >> >> ^ >> SyntaxError: invalid syntax >> ------------- >> script is here: >> >> # >> # -- bbPlane.py - draws a CGO plane across the backbone atoms of >> # neighboring amino acids >> # >> # Author: Jason Vertrees, 06/2010 >> # Modified by Thomas Holder, 06/2010 >> # Modified by Blaine Bell, 08/2011 >> # Copyright (C) Schrodinger >> # Open Source License: MIT >> # >> from pymol.cgo import * # get constants >> from pymol import cmd, stored >> from chempy import cpv >> >> def bbPlane(objSel='(all)', color='white', transp=0.0): >> """ >> DESCRIPTION >> >> Draws a plane across the backbone for a selection >> >> ARGUMENTS >> >> objSel = string: protein object or selection {default: (all)} >> >> color = string: color name or number {default: white} >> >> transp = float: transparency component (0.0--1.0) {default: 0.0} >> >> NOTES >> >> You need to pass in an object or selection with at least two >> amino acids. The plane spans CA_i, O_i, N-H_(i+1), and CA_(i+1) >> """ >> # format input >> transp = float(transp) >> stored.AAs = [] >> coords = dict() >> >> # need hydrogens on peptide nitrogen >> cmd.h_add('(%s) and n. N' % objSel) >> >> # get the list of residue ids >> for obj in cmd.get_object_list(objSel): >> sel = obj + " and (" + objSel + ")" >> for a in cmd.get_model(sel + " and n. CA").atom: >> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >> stored.AAs.append(key) >> coords[key] = [a.coord,None,None] >> for a in cmd.get_model(sel + " and n. O").atom: >> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >> if key in coords: >> coords[key][1] = a.coord >> for a in cmd.get_model("(hydro or n. CD) and nbr. (" + sel + " and >> n. N)").atom: >> key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) >> if key in coords: >> coords[key][2] = a.coord >> >> # need at least two amino acids >> if len(stored.AAs) <= 1: >> print "ERROR: Please provide at least two amino acids, the >> alpha-carbon on the 2nd is needed." >> return >> >> # prepare the cgo >> obj = [ >> BEGIN, TRIANGLES, >> COLOR, >> ] >> obj.extend(cmd.get_color_tuple(color)) >> >> for res in range(0, len(stored.AAs)-1): >> curIdx, nextIdx = str(stored.AAs[res]), str(stored.AAs[res+1]) >> >> # populate the position array >> pos = [coords[curIdx][0], coords[curIdx][1], coords[nextIdx][2], >> coords[nextIdx][0]] >> >> # if the data are incomplete for any residues, ignore >> if None in pos: >> print 'peptide bond %s -> %s incomplete' % (curIdx, nextIdx) >> continue >> >> if cpv.distance(pos[0], pos[3]) > 4.0: >> print '%s and %s not adjacent' % (curIdx, nextIdx) >> continue >> >> # need to order vertices to generate correct triangles for plane >> # modified/added by B.Bell 8/18/2011 >> sumpos = cpv.add(pos[0], cpv.add(pos[1], cpv.add(pos[2], pos[3]))) >> centerpos = [ sumpos[0]/4., sumpos[1]/4., sumpos[2]/4. ] >> angles = [ [ 0., 0 ] ] >> s00 = cpv.sub(pos[0], centerpos) >> for i in range(1,4): >> s = cpv.sub(pos[i], centerpos) >> ang = cpv.get_angle(s00, s) >> angles.append( [ ang, i] ) >> def sortfirst(a, b): >> return cmp(a[0], b[0]) >> angles.sort(sortfirst) >> verts = map(lambda x: x[1], angles) >> vorder = [ verts[0], verts[1], verts[2], >> verts[1], verts[3], verts[2] ] >> # fill in the vertex data for the triangles; >> for i in vorder: >> obj.append(VERTEX) >> obj.extend(pos[i]) >> >> # finish the CGO >> obj.append(END) >> >> # update the UI >> newName = cmd.get_unused_name("backbonePlane") >> cmd.load_cgo(obj, newName) >> cmd.set("cgo_transparency", transp, newName) >> >> >> cmd.extend("bbPlane", bbPlane) >> >> artforscience >> H. Adam Steinberg >> Artist, Scientist, Developmental Editor >> www.artforscience.com >> 7904 Bowman Rd >> Lodi, WI 53555 >> 608/729-5944 >> >> ------------------------------------------------------------------------------ >> EMC VNX: the world's simplest storage, starting under $10K >> The only unified storage solution that offers unified management >> Up to 160% more powerful than alternatives and 25% more efficient. >> Guaranteed. http://p.sf.net/sfu/emc-vnx-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 > Schrodinger, LLC > > (e) Jas...@sc... > (o) +1 (603) 374-7120 H. Adam Steinberg 7904 Bowman Rd Lodi, WI 53555 608/592-2366 |
From: Jason V. <jas...@sc...> - 2011-08-25 16:37:55
|
Hi Andrew, On Thu, Aug 25, 2011 at 8:51 AM, Malaby, Andrew <And...@um...> wrote: > I am working on a figure showing the sticks of one molecule interacting with the surface of another. I am trying to keep my normal coloring in a figure, but make background portions of the molecule lighter. I have tried "set fog" followed by chain and residue numbers, to no avail. The program responds, but no visible change occurs. I feel that I am missing something inherent in the program. Any help here would be greatly appreciated. The fog setting is really a numerical parameter in an equation---not just on and off. So try, set fog, 5 set fog, 10 Cheers, -- Jason -- Jason Vertrees, PhD PyMOL Product Manager Schrodinger, LLC (e) Jas...@sc... (o) +1 (603) 374-7120 |
From: Tsjerk W. <ts...@gm...> - 2011-08-25 16:29:04
|
Hi Adam, Here's an alternative script... The command is pplanes (peptide-planes): run triangles.py pplanes selection[, color[, alpha[, state[, name]]]] Hope it helps, Tsjerk On Thu, Aug 25, 2011 at 5:34 PM, H. Adam Steinberg <ad...@st...> wrote: > Hi all, > Can anyone help me with a problem that I am having trying to run a python > script? > I am trying to run the bbPlane script from the PyMOLWiki > <" rel="nofollow">http://www.pymolwiki.org/index.php/BbPlane> > I have copied the script from the web page, to a plain text document, saved > it as "bbPlane.py" but when I run it I get: > ------------ > PyMOL>run bbPlane.py > Traceback (most recent call last): > File "/Volumes/Port > 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 332, in parse > File "/Volumes/Port > 3/software/MacPyMOL.app/pymol/modules/pymol/parsing.py", line 455, in > run_file > File "bbPlane.py", line 14 > > ^ > SyntaxError: invalid syntax > ------------- > script is here: > > # > # -- bbPlane.py - draws a CGO plane across the backbone atoms of > # neighboring amino acids > # > # Author: Jason Vertrees, 06/2010 > # Modified by Thomas Holder, 06/2010 > # Modified by Blaine Bell, 08/2011 > # Copyright (C) Schrodinger > # Open Source License: MIT > # > from pymol.cgo import * # get constants > from pymol import cmd, stored > from chempy import cpv > > def bbPlane(objSel='(all)', color='white', transp=0.0): > """ > DESCRIPTION > > Draws a plane across the backbone for a selection > > ARGUMENTS > > objSel = string: protein object or selection {default: (all)} > > color = string: color name or number {default: white} > > transp = float: transparency component (0.0--1.0) {default: 0.0} > > NOTES > > You need to pass in an object or selection with at least two > amino acids. The plane spans CA_i, O_i, N-H_(i+1), and CA_(i+1) > """ > # format input > transp = float(transp) > stored.AAs = [] > coords = dict() > > # need hydrogens on peptide nitrogen > cmd.h_add('(%s) and n. N' % objSel) > > # get the list of residue ids > for obj in cmd.get_object_list(objSel): > sel = obj + " and (" + objSel + ")" > for a in cmd.get_model(sel + " and n. CA").atom: > key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) > stored.AAs.append(key) > coords[key] = [a.coord,None,None] > for a in cmd.get_model(sel + " and n. O").atom: > key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) > if key in coords: > coords[key][1] = a.coord > for a in cmd.get_model("(hydro or n. CD) and nbr. (" + sel + " and > n. N)").atom: > key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) > if key in coords: > coords[key][2] = a.coord > > # need at least two amino acids > if len(stored.AAs) <= 1: > print "ERROR: Please provide at least two amino acids, the > alpha-carbon on the 2nd is needed." > return > > # prepare the cgo > obj = [ > BEGIN, TRIANGLES, > COLOR, > ] > obj.extend(cmd.get_color_tuple(color)) > > for res in range(0, len(stored.AAs)-1): > curIdx, nextIdx = str(stored.AAs[res]), str(stored.AAs[res+1]) > > # populate the position array > pos = [coords[curIdx][0], coords[curIdx][1], coords[nextIdx][2], > coords[nextIdx][0]] > > # if the data are incomplete for any residues, ignore > if None in pos: > print 'peptide bond %s -> %s incomplete' % (curIdx, nextIdx) > continue > > if cpv.distance(pos[0], pos[3]) > 4.0: > print '%s and %s not adjacent' % (curIdx, nextIdx) > continue > > # need to order vertices to generate correct triangles for plane > # modified/added by B.Bell 8/18/2011 > sumpos = cpv.add(pos[0], cpv.add(pos[1], cpv.add(pos[2], pos[3]))) > centerpos = [ sumpos[0]/4., sumpos[1]/4., sumpos[2]/4. ] > angles = [ [ 0., 0 ] ] > s00 = cpv.sub(pos[0], centerpos) > for i in range(1,4): > s = cpv.sub(pos[i], centerpos) > ang = cpv.get_angle(s00, s) > angles.append( [ ang, i] ) > def sortfirst(a, b): > return cmp(a[0], b[0]) > angles.sort(sortfirst) > verts = map(lambda x: x[1], angles) > vorder = [ verts[0], verts[1], verts[2], > verts[1], verts[3], verts[2] ] > # fill in the vertex data for the triangles; > for i in vorder: > obj.append(VERTEX) > obj.extend(pos[i]) > > # finish the CGO > obj.append(END) > > # update the UI > newName = cmd.get_unused_name("backbonePlane") > cmd.load_cgo(obj, newName) > cmd.set("cgo_transparency", transp, newName) > > > cmd.extend("bbPlane", bbPlane) > > artforscience > H. Adam Steinberg > Artist, Scientist, Developmental Editor > www.artforscience.com > 7904 Bowman Rd > Lodi, WI 53555 > 608/729-5944 > > ------------------------------------------------------------------------------ > EMC VNX: the world's simplest storage, starting under $10K > The only unified storage solution that offers unified management > Up to 160% more powerful than alternatives and 25% more efficient. > Guaranteed. http://p.sf.net/sfu/emc-vnx-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... > -- Tsjerk A. Wassenaar, Ph.D. post-doctoral researcher Molecular Dynamics Group * Groningen Institute for Biomolecular Research and Biotechnology * Zernike Institute for Advanced Materials University of Groningen The Netherlands |
From: Jason V. <jas...@sc...> - 2011-08-25 16:09:29
|
Hi Adam, I just copy/pasted the script you attached in your email and it worked fine. There are, however two spaces on line 14--maybe the parser thinks it found a block indent? Try erasing line 14 (the line following "from chempy import cpv") and re-running the script. Cheers, -- Jason On Thu, Aug 25, 2011 at 11:34 AM, H. Adam Steinberg <ad...@st...> wrote: > Hi all, > Can anyone help me with a problem that I am having trying to run a python > script? > I am trying to run the bbPlane script from the PyMOLWiki > <" rel="nofollow">http://www.pymolwiki.org/index.php/BbPlane> > I have copied the script from the web page, to a plain text document, saved > it as "bbPlane.py" but when I run it I get: > ------------ > PyMOL>run bbPlane.py > Traceback (most recent call last): > File "/Volumes/Port > 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 332, in parse > File "/Volumes/Port > 3/software/MacPyMOL.app/pymol/modules/pymol/parsing.py", line 455, in > run_file > File "bbPlane.py", line 14 > > ^ > SyntaxError: invalid syntax > ------------- > script is here: > > # > # -- bbPlane.py - draws a CGO plane across the backbone atoms of > # neighboring amino acids > # > # Author: Jason Vertrees, 06/2010 > # Modified by Thomas Holder, 06/2010 > # Modified by Blaine Bell, 08/2011 > # Copyright (C) Schrodinger > # Open Source License: MIT > # > from pymol.cgo import * # get constants > from pymol import cmd, stored > from chempy import cpv > > def bbPlane(objSel='(all)', color='white', transp=0.0): > """ > DESCRIPTION > > Draws a plane across the backbone for a selection > > ARGUMENTS > > objSel = string: protein object or selection {default: (all)} > > color = string: color name or number {default: white} > > transp = float: transparency component (0.0--1.0) {default: 0.0} > > NOTES > > You need to pass in an object or selection with at least two > amino acids. The plane spans CA_i, O_i, N-H_(i+1), and CA_(i+1) > """ > # format input > transp = float(transp) > stored.AAs = [] > coords = dict() > > # need hydrogens on peptide nitrogen > cmd.h_add('(%s) and n. N' % objSel) > > # get the list of residue ids > for obj in cmd.get_object_list(objSel): > sel = obj + " and (" + objSel + ")" > for a in cmd.get_model(sel + " and n. CA").atom: > key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) > stored.AAs.append(key) > coords[key] = [a.coord,None,None] > for a in cmd.get_model(sel + " and n. O").atom: > key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) > if key in coords: > coords[key][1] = a.coord > for a in cmd.get_model("(hydro or n. CD) and nbr. (" + sel + " and > n. N)").atom: > key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) > if key in coords: > coords[key][2] = a.coord > > # need at least two amino acids > if len(stored.AAs) <= 1: > print "ERROR: Please provide at least two amino acids, the > alpha-carbon on the 2nd is needed." > return > > # prepare the cgo > obj = [ > BEGIN, TRIANGLES, > COLOR, > ] > obj.extend(cmd.get_color_tuple(color)) > > for res in range(0, len(stored.AAs)-1): > curIdx, nextIdx = str(stored.AAs[res]), str(stored.AAs[res+1]) > > # populate the position array > pos = [coords[curIdx][0], coords[curIdx][1], coords[nextIdx][2], > coords[nextIdx][0]] > > # if the data are incomplete for any residues, ignore > if None in pos: > print 'peptide bond %s -> %s incomplete' % (curIdx, nextIdx) > continue > > if cpv.distance(pos[0], pos[3]) > 4.0: > print '%s and %s not adjacent' % (curIdx, nextIdx) > continue > > # need to order vertices to generate correct triangles for plane > # modified/added by B.Bell 8/18/2011 > sumpos = cpv.add(pos[0], cpv.add(pos[1], cpv.add(pos[2], pos[3]))) > centerpos = [ sumpos[0]/4., sumpos[1]/4., sumpos[2]/4. ] > angles = [ [ 0., 0 ] ] > s00 = cpv.sub(pos[0], centerpos) > for i in range(1,4): > s = cpv.sub(pos[i], centerpos) > ang = cpv.get_angle(s00, s) > angles.append( [ ang, i] ) > def sortfirst(a, b): > return cmp(a[0], b[0]) > angles.sort(sortfirst) > verts = map(lambda x: x[1], angles) > vorder = [ verts[0], verts[1], verts[2], > verts[1], verts[3], verts[2] ] > # fill in the vertex data for the triangles; > for i in vorder: > obj.append(VERTEX) > obj.extend(pos[i]) > > # finish the CGO > obj.append(END) > > # update the UI > newName = cmd.get_unused_name("backbonePlane") > cmd.load_cgo(obj, newName) > cmd.set("cgo_transparency", transp, newName) > > > cmd.extend("bbPlane", bbPlane) > > artforscience > H. Adam Steinberg > Artist, Scientist, Developmental Editor > www.artforscience.com > 7904 Bowman Rd > Lodi, WI 53555 > 608/729-5944 > > ------------------------------------------------------------------------------ > EMC VNX: the world's simplest storage, starting under $10K > The only unified storage solution that offers unified management > Up to 160% more powerful than alternatives and 25% more efficient. > Guaranteed. http://p.sf.net/sfu/emc-vnx-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 Schrodinger, LLC (e) Jas...@sc... (o) +1 (603) 374-7120 |
From: H. A. S. <ad...@st...> - 2011-08-25 15:47:59
|
Hi all, Can anyone help me with a problem that I am having trying to run a python script? I am trying to run the bbPlane script from the PyMOLWiki <" rel="nofollow">http://www.pymolwiki.org/index.php/BbPlane> I have copied the script from the web page, to a plain text document, saved it as "bbPlane.py" but when I run it I get: ------------ PyMOL>run bbPlane.py Traceback (most recent call last): File "/Volumes/Port 3/software/MacPyMOL.app/pymol/modules/pymol/parser.py", line 332, in parse File "/Volumes/Port 3/software/MacPyMOL.app/pymol/modules/pymol/parsing.py", line 455, in run_file File "bbPlane.py", line 14 ^ SyntaxError: invalid syntax ------------- script is here: # # -- bbPlane.py - draws a CGO plane across the backbone atoms of # neighboring amino acids # # Author: Jason Vertrees, 06/2010 # Modified by Thomas Holder, 06/2010 # Modified by Blaine Bell, 08/2011 # Copyright (C) Schrodinger # Open Source License: MIT # from pymol.cgo import * # get constants from pymol import cmd, stored from chempy import cpv def bbPlane(objSel='(all)', color='white', transp=0.0): """ DESCRIPTION Draws a plane across the backbone for a selection ARGUMENTS objSel = string: protein object or selection {default: (all)} color = string: color name or number {default: white} transp = float: transparency component (0.0--1.0) {default: 0.0} NOTES You need to pass in an object or selection with at least two amino acids. The plane spans CA_i, O_i, N-H_(i+1), and CA_(i+1) """ # format input transp = float(transp) stored.AAs = [] coords = dict() # need hydrogens on peptide nitrogen cmd.h_add('(%s) and n. N' % objSel) # get the list of residue ids for obj in cmd.get_object_list(objSel): sel = obj + " and (" + objSel + ")" for a in cmd.get_model(sel + " and n. CA").atom: key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) stored.AAs.append(key) coords[key] = [a.coord,None,None] for a in cmd.get_model(sel + " and n. O").atom: key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) if key in coords: coords[key][1] = a.coord for a in cmd.get_model("(hydro or n. CD) and nbr. (" + sel + " and n. N)").atom: key = '/%s/%s/%s/%s' % (obj,a.segi,a.chain,a.resi) if key in coords: coords[key][2] = a.coord # need at least two amino acids if len(stored.AAs) <= 1: print "ERROR: Please provide at least two amino acids, the alpha-carbon on the 2nd is needed." return # prepare the cgo obj = [ BEGIN, TRIANGLES, COLOR, ] obj.extend(cmd.get_color_tuple(color)) for res in range(0, len(stored.AAs)-1): curIdx, nextIdx = str(stored.AAs[res]), str(stored.AAs[res+1]) # populate the position array pos = [coords[curIdx][0], coords[curIdx][1], coords[nextIdx][2], coords[nextIdx][0]] # if the data are incomplete for any residues, ignore if None in pos: print 'peptide bond %s -> %s incomplete' % (curIdx, nextIdx) continue if cpv.distance(pos[0], pos[3]) > 4.0: print '%s and %s not adjacent' % (curIdx, nextIdx) continue # need to order vertices to generate correct triangles for plane # modified/added by B.Bell 8/18/2011 sumpos = cpv.add(pos[0], cpv.add(pos[1], cpv.add(pos[2], pos[3]))) centerpos = [ sumpos[0]/4., sumpos[1]/4., sumpos[2]/4. ] angles = [ [ 0., 0 ] ] s00 = cpv.sub(pos[0], centerpos) for i in range(1,4): s = cpv.sub(pos[i], centerpos) ang = cpv.get_angle(s00, s) angles.append( [ ang, i] ) def sortfirst(a, b): return cmp(a[0], b[0]) angles.sort(sortfirst) verts = map(lambda x: x[1], angles) vorder = [ verts[0], verts[1], verts[2], verts[1], verts[3], verts[2] ] # fill in the vertex data for the triangles; for i in vorder: obj.append(VERTEX) obj.extend(pos[i]) # finish the CGO obj.append(END) # update the UI newName = cmd.get_unused_name("backbonePlane") cmd.load_cgo(obj, newName) cmd.set("cgo_transparency", transp, newName) cmd.extend("bbPlane", bbPlane) artforscience H. Adam Steinberg Artist, Scientist, Developmental Editor www.artforscience.com 7904 Bowman Rd Lodi, WI 53555 608/729-5944 |
From: Michael L. <mgl...@gm...> - 2011-08-25 13:24:11
|
I don't know what the current stance on such things is, and Schrodinger's acquisition of PyMOL might have changed things, but I remember two very clear messages from Warren relating to Windows compilation. I'd read these and think about them pretty carefully before you go out of your way to do the seemingly obvious thing and make Windows compilation easier. The first is from 2007: http://www.mail-archive.com/pym...@li.../msg05696.html > > The goal is > > to produce a Pymol that uses native Windows graphics, not one > > that requires X11. > > David, > > Please note that the goal behind Open-Source PyMOL (as maintained by DeLano > Scientific LLC) is to enable compilation under open-source operating > systems, and primarily, Linux with X11/GLUT. It not our current intent to > support, assist, or encourage native compilation of PyMOL open-source code > on closed-source operating systems, despite the fact that such compilation > is deliberately permitted under the unrestrictive open-source license terms. > > An open-source version targeting native Windows (via any means) would > necessarily comprise a fork of the project. Since such a fork would provide > a realistic alternative to DeLano Scientific LLC's precompiled incentive > builds for Windows, it could jeopardize our ability to continue funding > development of the open-source code. > > If PyMOL revenues were imperiled, then to make ends meet, DeLano Scientific > LLC would have no choice but to redirect development efforts into > proprietary assets, significantly curtailing participation in the > unrestricted open-source project. At the very least, our unrestrictive > open-source license would have to be restricted in future versions, thus > defeating one of the primary aims of the project. > > We don't want that... do you? > > If not, then proceed down this path only with due care and consideration of > the possible consequences. Given enough effort, native compilation is > certainly do-able, but it is not intended to be easy... nor commonplace. > > To the extent that you achieve your goal, please do think twice before > publicly sharing the fruits and/or details of that success. We would > naturally prefer that such accomplishments remain private, since the future > of PyMOL could well depend upon it. > > With great freedom comes great responsibility! ;) > > Warren L. DeLano > DeLano Scientific LLC The second is from 2009 http://www.mail-archive.com/pym...@li.../msg06761.html > Bryn & others, > > By design, the PyMOL Open-Source Code only targets Linux and other 100% > open-source operating systems (e.g. FreeBSD). So to compile Open-Source > PyMOL on Mac OS X or Microsoft Windows, you need to pretend you are > running Linux by making use of X11 and the various GNU-compatible > free-software porting systems (e.g. Fink, GNU-Darwin, Cygwin, etc.). > > Also by design, the current precompiled PyMOL builds for proprietary > operating systems (i.e. Microsoft Windows & Mac OS X) are themselves > proprietary products offered by DeLano Scientific LLC. > > In other words, if you are willing to pay to use a proprietary operating > system, then we feel you should be equally willing to support the PyMOL > project financially via paid subscription access to our current builds > for proprietary platforms. That, indeed, is how we make ends meet while > still keeping the PyMOL code open-source. > > For those who are not able to support the project financially, well, > there are still plenty of older PyMOL builds for Mac & Windows floating > around the internet. They just don't include the latest fixes & > features. Of course, without a subscription, you don't have access to > all the documentation -- only the public portion ( http://pymolwiki.org > ). > > Please visit http://pymol.org/funding.html if you wish to purchase a > subscription. > > Cheers, > Warren > > PS. FREE builds for educational-use-only can be had via > http://pymol.org/educational.html 2011/8/24 Troels Emtekær Linnet <tl...@gm...> > After some tries, I found that that the .reg file should be changed a > little. > Then .pdb files gets icon and gets opened by pymol.cmd > > C:\Python2X\PyMOL\PDB_file.reg > > REGEDIT4 > > [-HKEY_CLASSES_ROOT\.pdb] > > [HKEY_CLASSES_ROOT\.pdb] > @="PDB.File" > "Content Type"="chemical/x-pdb" > > [-HKEY_CLASSES_ROOT\PDB.File] > > [HKEY_CLASSES_ROOT\PDB.File] > @="PDB File" > > [HKEY_CLASSES_ROOT\PDB.File\DefaultIcon] > @="C:\\Python27\\PyMOL\\PyMOL.exe" > > [HKEY_CLASSES_ROOT\PDB.File\Shell] > @="" > > [HKEY_CLASSES_ROOT\PDB.File\Shell\open] > > [HKEY_CLASSES_ROOT\PDB.File\Shell\open\command] > @="\"C:\\Python27\\PyMOL\\PyMOL.cmd\" %*" > > [-HKEY_CLASSES_ROOT\pdb_auto_file] > > [HKEY_CLASSES_ROOT\pdb_auto_file] > @="PDB File" > > [HKEY_CLASSES_ROOT\pdb_auto_file\DefaultIcon] > @="C:\\Python27\\PyMOL\\PyMOL.exe" > > [HKEY_CLASSES_ROOT\pdb_auto_file\Shell] > @="" > > [HKEY_CLASSES_ROOT\pdb_auto_file\Shell\open] > > [HKEY_CLASSES_ROOT\pdb_auto_file\Shell\open\command] > @="\"C:\\Python27\\PyMOL\\PyMOL.cmd\" %*" > > > > 2011/8/24 Troels Emtekær Linnet <tl...@gm...> > >> Hi. >> >> I was very happy to find a post how to easy install pymol 1.4 from source >> on windows. >> >> 1) Install python, 2.5, or 2.6 or 2.7 for windows. >> 2) Download appropriate installer from: >> http://www.lfd.uci.edu/~gohlke/pythonlibs/#pymol Select according to >> your python version. >> 3) Run it >> 4) PyMOL is now installed in: C:\Python2X\PyMOL >> >> A) C:\Python2X\PyMOL\PDB_file.reg should be edited in a text editor, to >> match your python version. Run it. >> B) Pymol is started by clicking C:\Python27\PyMOL\pymol.cmd which >> executes python on C:\Python27\PyMOL\pymol-launch.py >> >> Happy pymoling. >> >> Best >> Troels >> > > > > ------------------------------------------------------------------------------ > EMC VNX: the world's simplest storage, starting under $10K > The only unified storage solution that offers unified management > Up to 160% more powerful than alternatives and 25% more efficient. > Guaranteed. http://p.sf.net/sfu/emc-vnx-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... > -- Michael Lerner, Ph.D. IRTA Postdoctoral Fellow Laboratory of Computational Biology NIH/NHLBI 5635 Fishers Lane, Room T909, MSC 9314 Rockville, MD 20852 (UPS/FedEx/Reality) Bethesda MD 20892-9314 (USPS) |
From: Malaby, A. <And...@um...> - 2011-08-25 12:52:15
|
This is a very basic question, but I have been having trouble with this for a couple of days. I am working in pymol for Windows, but have access to Mac pymol if the problem is a windows-specific problem. I am working on a figure showing the sticks of one molecule interacting with the surface of another. I am trying to keep my normal coloring in a figure, but make background portions of the molecule lighter. I have tried "set fog" followed by chain and residue numbers, to no avail. The program responds, but no visible change occurs. I feel that I am missing something inherent in the program. Any help here would be greatly appreciated. Thanks! Andrew Malaby University of Massachusetts Medical School. |