Hi Giacomo,
you can either create an atom at that position
(see eg. http://www.rubor.de/bioinf/tips_python.html#chempy) and than
use the distance command (or wizard).
Or you can get the position of your first atom and simply calculate the
distance of the two positions,
sth. like:
class MyAtom:
def __init__(self, selection = "/1lov//A/1/CA"):
model = cmd.get_model(selection)
self.coordinates = self.model.atom[0].coord ## requires at least
one atom in the model
def distance(self, coords): ## given some coordinates (list of three),
from numarray import *
distanceVector=array(self.coordinates)-array(coords)
return sqrt(dot(distanceVector, distanceVector))
Hope, that's what you wanted!
Cheers,
Andreas
Giacomo Bastianelli wrote:
Dear Pymol users,
I would like to measure the distance between an atom and
a specific point (not another atom) in the surface of the protein.
Is it possible with pymol?
do I need additional scripts?
Thanks in advance,
Giacomo Bastianelli
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
PyMOL-users mailing list
PyMOL-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pymol-users
--
Andreas Henschel
Bioinformatics Group
TU Dresden
Tatzberg 47-51
01307 Dresden, Germany
Phone: +49 351 463 40063
EMail: a...@biotec.tu-dresden.de