Hi, All,
I am writing a script to find all salt bridges in a pentameric proteins in 50
models.
The issues are
1. There are no salt bridges found in the same chain. But I find some if I
use this command.
>pairwise_dist /model00000//A/LYS+ARG/NZ+NE+NH*,
>/model00000//A/ASP+GLU/OD*+OE*, 4, show=N, output=P
My guess is that pairwise_dist does not take the same sel1, sel2 as a valid
input. Any solutions/suggestions?
2. The script is apparently not optimized. Any suggestions?
Thanks!
Charles
Here are what I am using now.
from pymol import cmd
from glob import glob
for file in glob("model*.pdb"):
print(file)
cmd.load(file)
obj=cmd.get_object_list('all')
print(obj)
#salt bridge
cmd.do("pairwise_dist ///A/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///A/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_A_A")
cmd.do("pairwise_dist ///A/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///B/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_A_B")
cmd.do("pairwise_dist ///A/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///C/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_A_C")
cmd.do("pairwise_dist ///A/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///D/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_A_D")
cmd.do("pairwise_dist ///A/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///E/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_A_E")
cmd.do("pairwise_dist ///B/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///B/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_B_B")
cmd.do("pairwise_dist ///B/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///C/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_B_C")
cmd.do("pairwise_dist ///B/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///D/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_B_D")
cmd.do("pairwise_dist ///B/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///E/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_B_E")
cmd.do("pairwise_dist ///C/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///C/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_C_C")
cmd.do("pairwise_dist ///C/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///D/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_C_D")
cmd.do("pairwise_dist ///C/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///E/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_C_E")
cmd.do("pairwise_dist ///D/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///D/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_D_D")
cmd.do("pairwise_dist ///D/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///E/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_D_E")
cmd.do("pairwise_dist ///E/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*,
///E/ASP+GLU+LYS+ARG/OD*+OE*+NZ+NE+NH*, 4, show=N, output="+str(obj[0])+"_E_E")
cmd.delete("all")
_______________________________________________
PyMOL-users mailing list
Archives: http://www.mail-archive.com/[email protected]
Unsubscribe:
https://sourceforge.net/projects/pymol/lists/pymol-users/unsubscribe