Re: [PyMOL] Access to pymol commands from the terminal
Hi Tsjerk, Thanks alot! Also I have the task to merge protein.pdb and lipids.pdb with some 1 line shell command ( like CAT) to obtain protein inserted in the lipids (the seccond file is consist of the whole which can locate the protein). My problem is that both protein.pdb and lipids.pdb consisted of the unusuall first line which should be deleated before it merging (in my case it's the HEADER lala.pdb). could you suggest me the combination of grep sed command which should be used to deleate the first line from both pdbs and than merge it in one-command method? Many thanks, James 2014-09-04 12:48 GMT+04:00 Tsjerk Wassenaar tsje...@gmail.com: Hi James, You can use pymol -cd pymolcommands. See http://www.pymolwiki.org/index.php/Command_Line_Options However, the first part is much easier with grep or sed. To remove all solvent molecules: grep -v ^ATOM.*SOL in.pdb out.pdb To remove NA+/CL- too grep -v ATOM.*\(SOL\|NA+\|CL-\) in.pdb out.pdb The fitting is a bit more cumbersome :) Hope it helps, Tsjerk On Thu, Sep 4, 2014 at 10:19 AM, James Starlight jmsstarli...@gmail.com wrote: Dear PyMol users! I'd like to find possibilities for running of some pymol commands from the terminal. For instance in my case I' d like perform 2 simple steps (both in terminal not in the pymol GUI) to remove water and ions from my target input pdb (typical I do it via gromacs editconf) superimpose target.pdb against reference.pdb ( i do it by means of tmalign utility) Thanks for help, James -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/ ___ 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 -- Tsjerk A. Wassenaar, Ph.D. -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/___ 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
Re: [PyMOL] Access to pymol commands from the terminal
one question :) could someone explain me the ussage the pymol commands from the shell on the example e.g i need to load 2 pdbs in pymol make its superimposition and than save one of the superimposed pdb like load ref.pdb tar.pdb super tar, ref save tar tar_superimposed.pdb I've tried to do part of this using pymol ref.pdb tarr.pdb -cd super tarr ref but eventually obtained error James 2014-09-04 15:47 GMT+02:00 James Starlight jmsstarli...@gmail.com: Thanks Guys! I'll check the tutorials. All the best, James 2014-09-04 13:15 GMT+02:00 David Hall li...@cowsandmilk.net: (sed '1d' protein.pdb; sed '1d' lipid.pdb) merged.pdb --or-- tail -q -n '+2' protein.pdb lipid.pdb merged.pdb -David On Thu, Sep 4, 2014 at 6:19 AM, James Starlight jmsstarli...@gmail.com wrote: Hi Tsjerk, Thanks alot! Also I have the task to merge protein.pdb and lipids.pdb with some 1 line shell command ( like CAT) to obtain protein inserted in the lipids (the seccond file is consist of the whole which can locate the protein). My problem is that both protein.pdb and lipids.pdb consisted of the unusuall first line which should be deleated before it merging (in my case it's the HEADER lala.pdb). could you suggest me the combination of grep sed command which should be used to deleate the first line from both pdbs and than merge it in one-command method? Many thanks, James 2014-09-04 12:48 GMT+04:00 Tsjerk Wassenaar tsje...@gmail.com: Hi James, You can use pymol -cd pymolcommands. See http://www.pymolwiki.org/index.php/Command_Line_Options However, the first part is much easier with grep or sed. To remove all solvent molecules: grep -v ^ATOM.*SOL in.pdb out.pdb To remove NA+/CL- too grep -v ATOM.*\(SOL\|NA+\|CL-\) in.pdb out.pdb The fitting is a bit more cumbersome :) Hope it helps, Tsjerk On Thu, Sep 4, 2014 at 10:19 AM, James Starlight jmsstarli...@gmail.com wrote: Dear PyMol users! I'd like to find possibilities for running of some pymol commands from the terminal. For instance in my case I' d like perform 2 simple steps (both in terminal not in the pymol GUI) to remove water and ions from my target input pdb (typical I do it via gromacs editconf) superimpose target.pdb against reference.pdb ( i do it by means of tmalign utility) Thanks for help, James -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/ ___ 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 -- Tsjerk A. Wassenaar, Ph.D. -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/ ___ 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 -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/___ 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
Re: [PyMOL] Access to pymol commands from the terminal
Use the -h flag with grep to suppress the filename. Also, you don't need to pipe to cat, you can write directly to the file. grep -h '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdbmerged.pdb On 09/04/2014 10:38 AM, James Starlight wrote: ..and one question about grep (really didn't find it in the tutorial) using grep '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdb |catmerged.pdb I've obtained good pdb BUT each line prior to the ATOM the name of the pdb of the previous files have been added eg: tarr_se.pdb:ATOM 1 N ASP X 1 35.722 8.306 92.256 0.00 0.00 N tarr_se.pdb:ATOM 2 CA ASP X 1 35.252 8.836 93.529 0.00 0.00 C tarr_se.pdb:ATOM 3 C ASP X 1 35.797 10.339 93.708 0.00 0.00 C tarr_se.pdb:ATOM 4 O ASP X 1 34.979 11.297 93.674 0.00 0.00 O tarr_se.pdb:ATOM 5 CB ASP X 1 35.593 7.984 94.698 0.00 0.00 C tarr_se.pdb:ATOM 6 CG ASP X 1 34.692 8.171 95.960 0.00 0.00 C tarr_se.pdb:ATOM 7 OD1 ASP X 1 33.481 8.453 95.823 0.00 0.00 O tarr_se.pdb:ATOM 8 OD2 ASP X 1 35.257 8.362 97.046 0.00 0.00 O1- tarr_se.pdb:ATOM 9 HA ASP X 1 34.180 9.033 93.580 0.00 0.00 H tarr_se.pdb:ATOM 10 HB2 ASP X 1 35.496 6.916 94.504 0.00 0.00 H tarr_se.pdb:ATOM 11 HB3 ASP X 1 36.648 7.969 94.970 0.00 0.00 H such pattern are always produced by grep so I'd like that tarr_se.pdb: have not been included (of course I can it remove easily after merging but this step is not good for me :) ) Also i'll be very thankful for any useful grep awk sed tutorial in case of the bioinformatics application James 2014-09-04 16:03 GMT+02:00 James Starlight jmsstarli...@gmail.com mailto:jmsstarli...@gmail.com: one question :) could someone explain me the ussage the pymol commands from the shell on the example e.g i need to load 2 pdbs in pymol make its superimposition and than save one of the superimposed pdb like load ref.pdb tar.pdb super tar, ref save tar tar_superimposed.pdb I've tried to do part of this using pymol ref.pdb tarr.pdb -cd super tarr ref but eventually obtained error James 2014-09-04 15:47 GMT+02:00 James Starlight jmsstarli...@gmail.com mailto:jmsstarli...@gmail.com: Thanks Guys! I'll check the tutorials. All the best, James 2014-09-04 13:15 GMT+02:00 David Hall li...@cowsandmilk.net mailto:li...@cowsandmilk.net: (sed '1d' protein.pdb; sed '1d' lipid.pdb) merged.pdb --or-- tail -q -n '+2' protein.pdb lipid.pdb merged.pdb -David On Thu, Sep 4, 2014 at 6:19 AM, James Starlight jmsstarli...@gmail.com mailto:jmsstarli...@gmail.com wrote: Hi Tsjerk, Thanks alot! Also I have the task to merge protein.pdb and lipids.pdb with some 1 line shell command ( like CAT) to obtain protein inserted in the lipids (the seccond file is consist of the whole which can locate the protein). My problem is that both protein.pdb and lipids.pdb consisted of the unusuall first line which should be deleated before it merging (in my case it's the HEADER lala.pdb). could you suggest me the combination of grep sed command which should be used to deleate the first line from both pdbs and than merge it in one-command method? Many thanks, James 2014-09-04 12:48 GMT+04:00 Tsjerk Wassenaar tsje...@gmail.com mailto:tsje...@gmail.com: Hi James, You can use pymol -cd pymolcommands. See http://www.pymolwiki.org/index.php/Command_Line_Options However, the first part is much easier with grep or sed. To remove all solvent molecules: grep -v ^ATOM.*SOL in.pdb out.pdb To remove NA+/CL- too grep -v ATOM.*\(SOL\|NA+\|CL-\) in.pdb out.pdb The fitting is a bit more cumbersome :) Hope it helps, Tsjerk On Thu, Sep 4, 2014 at 10:19 AM, James Starlight jmsstarli...@gmail.com mailto:jmsstarli...@gmail.com wrote: Dear PyMol users! I'd like to find possibilities for running of some pymol commands from the terminal. For instance in my case I' d like perform 2 simple steps (both in
Re: [PyMOL] Access to pymol commands from the terminal
thanks! and do I need to pipe the below command to smth grep -h '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdbmerged.pdb if I need to change 'END' to 'TER' in the merged.pdb ? 2014-09-04 16:54 GMT+02:00 James Starlight jmsstarli...@gmail.com: thanks! and do I need to pipe the below command to smth grep -h '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdbmerged.pdb if I need to change 'END' to 'TER' in the merged.pdb ? 2014-09-04 16:41 GMT+02:00 Matthew Baumgartner mp...@pitt.edu: Use the -h flag with grep to suppress the filename. Also, you don't need to pipe to cat, you can write directly to the file. grep -h '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdbmerged.pdb On 09/04/2014 10:38 AM, James Starlight wrote: ..and one question about grep (really didn't find it in the tutorial) using grep '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdb |catmerged.pdb I've obtained good pdb BUT each line prior to the ATOM the name of the pdb of the previous files have been added eg: tarr_se.pdb:ATOM 1 N ASP X 1 35.722 8.306 92.256 0.00 0.00 N tarr_se.pdb:ATOM 2 CA ASP X 1 35.252 8.836 93.529 0.00 0.00 C tarr_se.pdb:ATOM 3 C ASP X 1 35.797 10.339 93.708 0.00 0.00 C tarr_se.pdb:ATOM 4 O ASP X 1 34.979 11.297 93.674 0.00 0.00 O tarr_se.pdb:ATOM 5 CB ASP X 1 35.593 7.984 94.698 0.00 0.00 C tarr_se.pdb:ATOM 6 CG ASP X 1 34.692 8.171 95.960 0.00 0.00 C tarr_se.pdb:ATOM 7 OD1 ASP X 1 33.481 8.453 95.823 0.00 0.00 O tarr_se.pdb:ATOM 8 OD2 ASP X 1 35.257 8.362 97.046 0.00 0.00 O1- tarr_se.pdb:ATOM 9 HA ASP X 1 34.180 9.033 93.580 0.00 0.00 H tarr_se.pdb:ATOM 10 HB2 ASP X 1 35.496 6.916 94.504 0.00 0.00 H tarr_se.pdb:ATOM 11 HB3 ASP X 1 36.648 7.969 94.970 0.00 0.00 H such pattern are always produced by grep so I'd like that tarr_se.pdb: have not been included (of course I can it remove easily after merging but this step is not good for me :) ) Also i'll be very thankful for any useful grep awk sed tutorial in case of the bioinformatics application James 2014-09-04 16:03 GMT+02:00 James Starlight jmsstarli...@gmail.com: one question :) could someone explain me the ussage the pymol commands from the shell on the example e.g i need to load 2 pdbs in pymol make its superimposition and than save one of the superimposed pdb like load ref.pdb tar.pdb super tar, ref save tar tar_superimposed.pdb I've tried to do part of this using pymol ref.pdb tarr.pdb -cd super tarr ref but eventually obtained error James 2014-09-04 15:47 GMT+02:00 James Starlight jmsstarli...@gmail.com: Thanks Guys! I'll check the tutorials. All the best, James 2014-09-04 13:15 GMT+02:00 David Hall li...@cowsandmilk.net: (sed '1d' protein.pdb; sed '1d' lipid.pdb) merged.pdb --or-- tail -q -n '+2' protein.pdb lipid.pdb merged.pdb -David On Thu, Sep 4, 2014 at 6:19 AM, James Starlight jmsstarli...@gmail.com wrote: Hi Tsjerk, Thanks alot! Also I have the task to merge protein.pdb and lipids.pdb with some 1 line shell command ( like CAT) to obtain protein inserted in the lipids (the seccond file is consist of the whole which can locate the protein). My problem is that both protein.pdb and lipids.pdb consisted of the unusuall first line which should be deleated before it merging (in my case it's the HEADER lala.pdb). could you suggest me the combination of grep sed command which should be used to deleate the first line from both pdbs and than merge it in one-command method? Many thanks, James 2014-09-04 12:48 GMT+04:00 Tsjerk Wassenaar tsje...@gmail.com: Hi James, You can use pymol -cd pymolcommands. See http://www.pymolwiki.org/index.php/Command_Line_Options However, the first part is much easier with grep or sed. To remove all solvent molecules: grep -v ^ATOM.*SOL in.pdb out.pdb To remove NA+/CL- too grep -v ATOM.*\(SOL\|NA+\|CL-\) in.pdb out.pdb The fitting is a bit more cumbersome :) Hope it helps, Tsjerk On Thu, Sep 4, 2014 at 10:19 AM, James Starlight jmsstarli...@gmail.com wrote: Dear PyMol users! I'd like to find possibilities for running of some pymol commands from the terminal. For instance in my case I' d like perform 2 simple steps (both in terminal not in the pymol GUI) to remove water and ions from my target input pdb (typical I do it via gromacs editconf) superimpose target.pdb against reference.pdb ( i do it by means of tmalign utility) Thanks for help, James -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/
Re: [PyMOL] Access to pymol commands from the terminal
You could make a python script that import pymol and does what you want from there. Some thing like this (untested); import __main__ __main__.pymol_argv = ['pymol','-cqk'] # Pymol: quiet and no GUI import pymol pymol.finish_launching() from pymol import cmd reffile = sys.argv[1] tarfile = sys.argv[2] outfile = sys.argv[3] cmd.load(reffile, 'ref') cmd.load(tarfile, 'tar') cmd.align('ref', 'tar') cmd.save(outfile, 'ref') Then on the command line call it like: python my_align.py reffile.pdb target.pdb output.pdb On 09/04/2014 11:06 AM, James Starlight wrote: thank you very much! so now only my question regarding the usage of the pymol commands in command line is still open BTW could someone suggest me the shell utility to make quick superimposition of the tar.pdb to ref.pdb and save superimposed tar.pdb as the separate pdb (the TMalign is not good because it produce pdb with both merged layers (and its backbone trace only) as the result if -o flagg is provided) Kind regards, Gleb 2014-09-04 16:57 GMT+02:00 Matthew Baumgartner mp...@pitt.edu mailto:mp...@pitt.edu: You can use sed grep -h '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdb | sed -e 's/^END/TER/g' merged.pdb On 09/04/2014 10:54 AM, James Starlight wrote: thanks! and do I need to pipe the below command to smth grep -h '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdb merged.pdb if I need to change 'END' to 'TER' in the merged.pdb ? 2014-09-04 16:41 GMT+02:00 Matthew Baumgartner mp...@pitt.edu mailto:mp...@pitt.edu: Use the -h flag with grep to suppress the filename. Also, you don't need to pipe to cat, you can write directly to the file. grep -h '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdb merged.pdb On 09/04/2014 10:38 AM, James Starlight wrote: ..and one question about grep (really didn't find it in the tutorial) using grep '^\(ATOM\|HETATM\|END\)' tarr_se.pdb lipids.pdb |cat merged.pdb I've obtained good pdb BUT each line prior to the ATOM the name of the pdb of the previous files have been added eg: tarr_se.pdb:ATOM 1 N ASP X 1 35.722 8.306 92.256 0.00 0.00 N tarr_se.pdb:ATOM 2 CA ASP X 1 35.252 8.836 93.529 0.00 0.00 C tarr_se.pdb:ATOM 3 C ASP X 1 35.797 10.339 93.708 0.00 0.00 C tarr_se.pdb:ATOM 4 O ASP X 1 34.979 11.297 93.674 0.00 0.00 O tarr_se.pdb:ATOM 5 CB ASP X 1 35.593 7.984 94.698 0.00 0.00 C tarr_se.pdb:ATOM 6 CG ASP X 1 34.692 8.171 95.960 0.00 0.00 C tarr_se.pdb:ATOM 7 OD1 ASP X 1 33.481 8.453 95.823 0.00 0.00 O tarr_se.pdb:ATOM 8 OD2 ASP X 1 35.257 8.362 97.046 0.00 0.00 O1- tarr_se.pdb:ATOM 9 HA ASP X 1 34.180 9.033 93.580 0.00 0.00 H tarr_se.pdb:ATOM 10 HB2 ASP X 1 35.496 6.916 94.504 0.00 0.00 H tarr_se.pdb:ATOM 11 HB3 ASP X 1 36.648 7.969 94.970 0.00 0.00 H such pattern are always produced by grep so I'd like that tarr_se.pdb: have not been included (of course I can it remove easily after merging but this step is not good for me :) ) Also i'll be very thankful for any useful grep awk sed tutorial in case of the bioinformatics application James 2014-09-04 16:03 GMT+02:00 James Starlight jmsstarli...@gmail.com mailto:jmsstarli...@gmail.com: one question :) could someone explain me the ussage the pymol commands from the shell on the example e.g i need to load 2 pdbs in pymol make its superimposition and than save one of the superimposed pdb like load ref.pdb tar.pdb super tar, ref save tar tar_superimposed.pdb I've tried to do part of this using pymol ref.pdb tarr.pdb -cd super tarr ref but eventually obtained error James 2014-09-04 15:47 GMT+02:00 James Starlight jmsstarli...@gmail.com mailto:jmsstarli...@gmail.com: Thanks Guys! I'll check the tutorials. All the best, James 2014-09-04 13:15 GMT+02:00 David Hall li...@cowsandmilk.net mailto:li...@cowsandmilk.net: (sed '1d' protein.pdb; sed '1d' lipid.pdb) merged.pdb --or-- tail -q -n '+2' protein.pdb lipid.pdb merged.pdb -David
Re: [PyMOL] map color turns to gray after ray
Hello, a bit more details. Pymol version: 1.3 in windows I did following: isomesh to show the maps on interested region(2F0-fc and anomalous map ), set mesh_width, 0.5 choose colors on the gui (colors can be shown correctly) ray (backbones still show as colors, but all the map mesh turns to gray) Many thanks. Yahui On Thu, Sep 4, 2014 at 4:34 PM, Yahui Yan yahu...@gmail.com wrote: Hello all, I am trying to show two electron density map with two colors. It works normally on the session. But after ray, all the mesh turns to gray, no matter which colors were chosen for the maps. Any suggestions? Many thanks. Yahui -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/___ 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
[PyMOL] PyMOL Open-Source Fellowship - Call for Applications
Greetings, I am excited to announce that the Warren L. DeLano Memorial PyMOL Open-Source Fellowship program is now accepting applications for the 2014--2015 term. The Fellowship is awarded by Schrӧdinger to supplement the income of an outstanding member of the PyMOL open-source community to develop free resources to help scientific progress and the community as a whole. Details and application instructions can be found on http://pymol.org/fellowship The application deadline is November 1st, 2014. We look forward to your submissions! Cheers, Thomas -- Thomas Holder PyMOL Developer Schrödinger, Inc. -- Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/ ___ 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