Skip to content

Commit

Permalink
improved anisou setter getter docs
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesmkrieger committed Nov 3, 2023
1 parent 876b406 commit 9563a22
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 13 deletions.
6 changes: 3 additions & 3 deletions prody/atomic/atom.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,21 +95,21 @@ def setCoords(self, coords):
self._ag._setTimeStamp(acsi)

def getAnisou(self):
"""Returns a copy of anisou of the atom from the active coordinate
"""Returns a copy of anisotropic temperature factors of the atom from the active coordinate
set."""

if self._ag._anisous is not None:
return self._ag._anisous[self.getACSIndex(), self._index].copy()

def _getAnisou(self):
"""Returns a view of anisou of the atom from the active coordinate
"""Returns a view of anisotropic temperature factors of the atom from the active coordinate
set."""

if self._ag._anisous is not None:
return self._ag._anisous[self.getACSIndex(), self._index]

def setAnisou(self, anisou):
"""Set anisou of the atom in the active coordinate set."""
"""Set anisotropic temperature factors of the atom in the active coordinate set."""

acsi = self.getACSIndex()
self._ag._anisous[acsi, self._index] = anisou
Expand Down
14 changes: 7 additions & 7 deletions prody/atomic/atomgroup.py
Original file line number Diff line number Diff line change
Expand Up @@ -576,19 +576,19 @@ def _setCoords(self, coords, label='', overwrite=False):
self._cslabels[acsi] = str(label)

def getAnisous(self):
"""Returns a copy of anisous from active coordinate set."""
"""Returns a copy of anisotropic temperature factors from active coordinate set."""

if self._anisous is not None:
return self._anisous[self._acsi].copy()

def _getAnisous(self):
"""Returns a view of anisous from active coordinate set."""
"""Returns a view of anisotropic temperature factors from active coordinate set."""

if self._anisous is not None:
return self._anisous[self._acsi]

def setAnisous(self, anisous, label=''):
"""Set anisous of atoms. *anisous* may be any array like object
"""Set anisotropic temperature factors of atoms. *anisous* may be any array like object
or an object instance with :meth:`getAnisous` method. If the shape of
anisou array is ``(n_csets > 1, n_atoms, 3)``, it will replace all
coordinate sets and the active coordinate set index will reset to
Expand Down Expand Up @@ -621,10 +621,10 @@ def setAnisous(self, anisous, label=''):
self._setAnisous(anisous, label=label)

def _setAnisous(self, anisous, label='', overwrite=False):
"""Set anisous without data type checking. *coords* must
be a :class:`~numpy.ndarray`, but may have data type other than
:class:`~numpy.float64`, e.g. :class:`~numpy.float32`. *label*
argument may be used to label coordinate sets. *label* may be
"""Set anisotropic temperature factors without data type checking.
*anisous* must be a :class:`~numpy.ndarray`, but may have data type
other than :class:`~numpy.float64`, e.g. :class:`~numpy.float32`.
*label* argument may be used to label coordinate sets. *label* may be
a string or a list of strings length equal to the number of
coordinate sets."""

Expand Down
2 changes: 1 addition & 1 deletion prody/atomic/select.py
Original file line number Diff line number Diff line change
Expand Up @@ -2426,7 +2426,7 @@ def _getCoords(self):
return self._coords

def _getAnisous(self):
"""Returns anisous of atoms."""
"""Returns anisotropic temperature factors of atoms."""

if self._anisous is None:
self._anisous = self._atoms._getAnisous()
Expand Down
4 changes: 2 additions & 2 deletions prody/atomic/subset.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def getCoords(self):
_getCoords = getCoords

def getAnisous(self):
"""Returns a copy of anisous from the active coordinate set."""
"""Returns a copy of anisotropic temperature factors from the active coordinate set."""

if self._ag._anisous is not None:
# Since this is not slicing, a view is not returned
Expand All @@ -80,7 +80,7 @@ def setCoords(self, coords):
self._ag._setTimeStamp(self.getACSIndex())

def setAnisous(self, anisous):
"""Set anisous in the active coordinate set."""
"""Set anisotropic temperature factors in the active coordinate set."""

if self._ag._anisous is not None:
self._ag._anisous[self.getACSIndex(), self._indices] = anisous
Expand Down

0 comments on commit 9563a22

Please sign in to comment.