Dear Pymol Users,
that is not very related to pymol question but however probably it can
be solved via pymol as well ;-)
I am looking for some script (e.g. via running in pymol no-gui), which
will count the number of standard amino acid residues in the given
PDB. E.g. for particular pdb
hi Jared,
I have tried to use your script putting it into my test.sh script
I only changed the selection statement in sel = 'tmp and
polymer.protein' instead of sel = 'tmp and chain A and
polymer.protein'
since in my protein there is no chains assigned
pdb="./NpXynWT_apo_340K_MD_multi_0434.pdb"
Hi James -
The PyMOL version you are using is quite old, and doesn't support the
'polymer.protein' selector. Try using just 'polymer' instead.
Hope that helps.
Jared
On June 24, 2019 at 11:58:54 AM, James Starlight (jmsstarli...@gmail.com) wrote:
hi Jared,
I have tried to use your
Hi James,
You can put Jared's commands (below the load command is replaced with the fetch
command)
in a bash script called cntRei.sh and pass the PDB-ID from the command line.
The $1 is a place holder for the first argument on the command line, the PDB-ID
in this case.
This will enable easy
Thank you, Jared!
how do you think would it be possible to run this command from no-gui pymol?
pymol -c -d "
from pymol import cmd
print len( set( [(i.chain,i.resi,i.resn) for i in
cmd.get_model(selection).atom] ) )
"
?
пн, 24 июн. 2019 г. в 16:17, Jared Sampson :
>
> Hi James -
>
> Do
Hi James -
Do any of the options from this previous BB discussion help?
https://sourceforge.net/p/pymol/mailman/message/28466955/
Cheers,
Jared
On June 24, 2019 at 8:13:47 AM, James Starlight (jmsstarli...@gmail.com) wrote:
Dear Pymol Users,
that is not very related to pymol question but
i also tried more simple sollution directly from terminal but it
doesn't work also
pymol -c -d "
from pymol import cmd
cmd.load('my.pdb')
cmd.count_atoms('n. CA')
"
actually what I do need is to compute number of residues and store it
in a variable (inside of my shell script)
пн, 24
Hi James -
You can give multiple commands by leaving the quote open as you did on the
first line (see Thomas' post from a day or two ago), but the `print` statement,
even though it is valid Python 2, will not work across line breaks as written
unless inside a `python` / `python end` block