Package schrodinger :: Package application :: Package phase :: Module phase_markers :: Class PhaseMarkers
[hide private]
[frames] | no frames]

Class PhaseMarkers

       object --+            
                |            
sip.simplewrapper --+        
                    |        
          sip.wrapper --+    
                        |    
     PyQt5.QtCore.QObject --+
                            |
                           PhaseMarkers

Class for adding pharmacophore feature markers and controlling their visibility.

Instance Methods [hide private]
 
editingFinished(...)
signal that gets emitted when feature editing is finished.
 
closeFeatureEditDialog(...)
signal that gets emitted when any open edit feature dialog should be closed.
 
__init__(self, *args, **kwargs)
x.__init__(...) initializes x; see help(type(x)) for signature
bool
featureExists(self, entry_id)
This function checks whether pharmacophore features exist for a structure with a given entry_id and returns True or False.
list
addStructureFeatures(self, st, fds, entry_id, allow_picking=True)
Add all pharmacophore feature markers for a given structure.
 
addSites(self, sites, entry_id, use_highlight=False, allow_picking=True)
Add pharmacophore features for given sites.
tuple
getFeature(self, feature_name, entry_id)
Retrieve markers for the specified feature.
list
getAllFeatures(self)
Retrieve markers for all features.
list
getSites(self, entry_id)
Get list of sites for all features with a given entry id.
list
getFeatureNames(self, entry_id)
Get list of feature names that were found for the structure with a given entry id.
list of ints
addFeaturesForWorkspaceLigands(self, fds, allow_picking=True)
Add feature markers for each included ligand PT entry, according to the given feature definitions.
 
_updateFeatures(self)
Show or hide features for entries that are included or excluded in the workspace.
 
removeFeature(self, feature_name, entry_id)
Removes markers for the specified pharmacophore feature.
 
removeAllFeatures(self)
Removes markers for all pharmacophore features.
 
removeAllFeaturesForEntry(self, entry_id)
Removes markers for all features associated with a given entry.
 
showFeature(self, feature_name, entry_id)
Show markers for the specified pharmacophore feature.
 
showAllFeatures(self)
Shows markers for all pharmacophore features.
 
showAllFeaturesForEntry(self, entry_id)
Shows markers for all features associated with a given entry.
 
_showFeatureForKey(self, feature_key)
Show markers for a given feature key.
 
hideFeature(self, feature_name, entry_id)
Hide markers for the specified pharmacophore feature.
 
hideAllFeatures(self)
Hide markers for all pharmacophore features.
 
hideAllFeaturesForEntry(self, entry_id)
Hide markers for all features associated with a given entry.
 
_hideFeatureForKey(self, feature_key)
Hide markers for a given feature key.
 
hasXvolMarkers(self, entry_id)
Checks whether excluded volume markers for a given entry ID exist.
 
removeXvolMarkers(self, entry_id)
Removes all excluded volume markers for a given entry.
 
removeXvolMarkersWithIDs(self, entry_id, sphere_indices)
Removes excluded volume markers with specified sphere ids for a given entry.
 
removeAllXvolMarkers(self)
Removes all excluded volume markers.
 
addXvolMarkers(self, entry_id, x_vol, interactive=False)
Adds excluded volume markers for a given entry ID.
int
findXvolSphereIndex(self, entry_id, pick_id)
Finds excluded volume sphere index for a given sphere pick id.
 
setXvolSelected(self, entry_id, sphere_indices)
Selects spheres with given sphere ids for a given entry id.
 
updateXvolMarker(self, entry_id, sphere_index, r, x, y, z)
This function is called to change radius and coordinates of excluded volume with a given sphere id and entry id.
 
hasTolMarkers(self, entry_id)
Checks whether tolerance markers for a given entry ID exist.
 
removeTolMarkers(self, entry_id)
Removes all tolerance markers for a given entry.
 
removeAllTolMarkers(self)
Removes all tolerance markers.
 
addTolMarkers(self, entry_id, sites)
Adds tolerance markers for a given entry ID.
schrodinger.MM_Project
projectModel(self)
Returns a Maestro project object.
 
hasRefCtMarker(self, entry_id)
Checks whether refernce ligand marker for a given entry ID exists.
 
removeRefCtMarker(self, entry_id)
Removes all reference ligand markers for a given entry.
 
removeAllRefCtMarkers(self)
Removes all reference ligand markers.
 
addRefCtMarker(self, entry_id, ref_ct)
Adds reference ligand markers for a given entry ID.
 
setSelection(self, features, entry_id, selected)
Sets selection mode for multiple features.
 
setFeatureSelection(self, feature_name, entry_id, selected)
Set specified pharmacophore feature selection mode.
 
clearSelection(self)
Clear 'selection' for all pharmacophore features.
 
setPropertyLabelVisible(self, entry_id, visible)
Shows or hides detailed (property) label for all feature markers.
(int, str)
_genFeatureKey(self, entry_id, feature_name)
Create a unique feature key.
list
_getKeysForEntry(self, entry_id)
Get a list of all feature keys for a given entry id.
set
_getEntryIDs(self)
Get a list of unique entry ids that feature markers stored in this mixin are associated with.
 
getFeatureFromId(self, marker_id)
Return the marker with the given ID.

Inherited from PyQt5.QtCore.QObject: __getattr__, blockSignals, childEvent, children, connectNotify, customEvent, deleteLater, destroyed, disconnect, disconnectNotify, dumpObjectInfo, dumpObjectTree, dynamicPropertyNames, event, eventFilter, findChild, findChildren, inherits, installEventFilter, isSignalConnected, isWidgetType, isWindowType, killTimer, metaObject, moveToThread, objectName, objectNameChanged, parent, property, pyqtConfigure, receivers, removeEventFilter, sender, senderSignalIndex, setObjectName, setParent, setProperty, signalsBlocked, startTimer, thread, timerEvent, tr

Inherited from sip.simplewrapper: __new__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]

Inherited from PyQt5.QtCore.QObject: staticMetaObject

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

editingFinished(...)

 
signal that gets emitted when feature editing is finished. This signal is emitted regardless of whether feature was changed or not.

closeFeatureEditDialog(...)

 
signal that gets emitted when any open edit feature dialog should be closed. This signal is emitted when the Phase GUI workflow changes, or the panel is closed.

__init__(self, *args, **kwargs)
(Constructor)

 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

featureExists(self, entry_id)

 

This function checks whether pharmacophore features exist for a structure with a given entry_id and returns True or False.

Parameters:
  • entry_id (int) - structure entry_id
Returns: bool
True if features were already added and False otherwise

addStructureFeatures(self, st, fds, entry_id, allow_picking=True)

 

Add all pharmacophore feature markers for a given structure.

Parameters:
  • st (structure.Structure) - molecule structure
  • fds (list) - list of feature definitions
  • entry_id (int) - structure entry id
  • allow_picking (bool) - whether this marker can be 'picked', which allows showing a context menu when right-clicked
Returns: list
list of sites that were added for this structure

addSites(self, sites, entry_id, use_highlight=False, allow_picking=True)

 

Add pharmacophore features for given sites.

Parameters:
  • sites (list of phase.PhpSite) - list of pharmacophore sites
  • entry_id (int) - structure entry id
  • use_highlight (list) - indicates whether sites should be 'highlighted'
  • allow_picking (bool) - whether this marker can be 'picked', which allows showing a context menu when right-clicked

getFeature(self, feature_name, entry_id)

 

Retrieve markers for the specified feature.

Parameters:
  • feature_name (str) - feature name
  • entry_id (int) - entry id of the structure that this feature is associated with
Returns: tuple
tuple that contains pharmacophore and projected points marker

getAllFeatures(self)

 

Retrieve markers for all features.

Returns: list
list of pharmacophore markers

getSites(self, entry_id)

 

Get list of sites for all features with a given entry id.

Parameters:
  • entry_id (int) - entry_id
Returns: list
list of sites

getFeatureNames(self, entry_id)

 

Get list of feature names that were found for the structure with a given entry id. Feature names are sorted in alphabetical order.

Parameters:
  • entry_id (int

    @return; list of feature names

    ) - entry_id
Returns: list

addFeaturesForWorkspaceLigands(self, fds, allow_picking=True)

 

Add feature markers for each included ligand PT entry, according to the given feature definitions.

Parameters:
  • fds - list of feature definitions
  • allow_picking - indicates whether feature can be 'picked'. When enabled this would make possible to show context menu when feature is right-clicked. Default is True. @type allow_picking
  • st (list)
Returns: list of ints
List of entry IDs for the included ligands.
Decorators:
  • @maestro_required

_updateFeatures(self)

 

Show or hide features for entries that are included or excluded in the workspace. Delete features for entries, which were deleted from the project.

removeFeature(self, feature_name, entry_id)

 

Removes markers for the specified pharmacophore feature.

Parameters:
  • feature_name - feature name
  • feature_name - str
  • entry_id (int) - entry id of the structure that this feature is associated with

removeAllFeaturesForEntry(self, entry_id)

 

Removes markers for all features associated with a given entry.

Parameters:
  • entry_id (int) - entry id of the structure that this feature is associated with

showFeature(self, feature_name, entry_id)

 

Show markers for the specified pharmacophore feature.

Parameters:
  • feature_name - feature name
  • feature_name - str
  • entry_id (int) - entry id of the structure that this feature is associated with

showAllFeaturesForEntry(self, entry_id)

 

Shows markers for all features associated with a given entry.

Parameters:
  • entry_id (int) - entry id of the structure that this feature is associated with

_showFeatureForKey(self, feature_key)

 

Show markers for a given feature key.

Parameters:
  • feature_key (str) - unique feature key.

hideFeature(self, feature_name, entry_id)

 

Hide markers for the specified pharmacophore feature.

Parameters:
  • feature_name - feature name
  • feature_name - str
  • entry_id (int) - entry id of the structure that this feature is associated with

hideAllFeaturesForEntry(self, entry_id)

 

Hide markers for all features associated with a given entry.

Parameters:
  • entry_id (int) - entry id of the structure that this feature is associated with

_hideFeatureForKey(self, feature_key)

 

Hide markers for a given feature key.

Parameters:
  • feature_key (str) - unique feature key.

hasXvolMarkers(self, entry_id)

 

Checks whether excluded volume markers for a given entry ID exist.

Parameters:
  • entry_id (int) - entry ID

removeXvolMarkers(self, entry_id)

 

Removes all excluded volume markers for a given entry.

Parameters:
  • entry_id (int) - entry ID

removeXvolMarkersWithIDs(self, entry_id, sphere_indices)

 

Removes excluded volume markers with specified sphere ids for a given entry.

Parameters:
  • entry_id (int) - entry ID
  • sphere_indices (list) - list of sphere indices

addXvolMarkers(self, entry_id, x_vol, interactive=False)

 

Adds excluded volume markers for a given entry ID.

Parameters:
  • entry_id (int) - entry ID
  • x_vol (phase.PhpExclVol) - data object that contains excluded volumes
  • interactive (bool) - indicates whether markers should be 'interactive'

findXvolSphereIndex(self, entry_id, pick_id)

 

Finds excluded volume sphere index for a given sphere pick id. Pick id is used to identify graphics3d objects picked in the Workspace.

Parameters:
  • entry_id (int) - entry ID
  • pick_id (int) - pick id of graphics3d object
Returns: int
index of sphere with a given pick id in the list that PhaseXvolMarkers object maintains.

setXvolSelected(self, entry_id, sphere_indices)

 

Selects spheres with given sphere ids for a given entry id.

Parameters:
  • entry_id (int) - entry ID
  • sphere_indices (list) - list of sphere indices

updateXvolMarker(self, entry_id, sphere_index, r, x, y, z)

 

This function is called to change radius and coordinates of excluded volume with a given sphere id and entry id.

Parameters:
  • entry_id (int) - entry ID
  • sphere_index (int) - sphere index
  • r (float) - new radius
  • x (float) - new x-coordinate
  • y (float) - new y-coordinate
  • z (float) - new z-coordinate

hasTolMarkers(self, entry_id)

 

Checks whether tolerance markers for a given entry ID exist.

Parameters:
  • entry_id (int) - entry ID

removeTolMarkers(self, entry_id)

 

Removes all tolerance markers for a given entry.

Parameters:
  • entry_id (int) - entry ID

addTolMarkers(self, entry_id, sites)

 

Adds tolerance markers for a given entry ID.

Parameters:
  • entry_id (int) - entry ID
  • sites (list of phase.PhpSite) - Phase hypothesis sites

projectModel(self)

 

Returns a Maestro project object.

Returns: schrodinger.MM_Project
Maestro project object.

hasRefCtMarker(self, entry_id)

 

Checks whether refernce ligand marker for a given entry ID exists.

Parameters:
  • entry_id (int) - entry ID

removeRefCtMarker(self, entry_id)

 

Removes all reference ligand markers for a given entry.

Parameters:
  • entry_id (int) - entry ID

addRefCtMarker(self, entry_id, ref_ct)

 

Adds reference ligand markers for a given entry ID.

Parameters:
  • entry_id (str) - entry ID
  • ref_ct (int

    @note ownership is transferred to maestro project.

    ) - data object that contains reference ligands

setSelection(self, features, entry_id, selected)

 

Sets selection mode for multiple features.

Parameters:
  • features (list) - list of feature names
  • entry_id (int) - entry id of the structure that this feature is associated with
  • selected (bool) - indicates whether feature should be selected or not

setFeatureSelection(self, feature_name, entry_id, selected)

 

Set specified pharmacophore feature selection mode. Shows glow effect around markers.

Parameters:
  • feature_name - feature name
  • feature_name - str
  • entry_id (int) - entry id of the structure that this feature is associated with
  • selected (bool) - indicates whether feature should be selected or not

setPropertyLabelVisible(self, entry_id, visible)

 

Shows or hides detailed (property) label for all feature markers.

Parameters:
  • entry_id (int) - entry id of the structure that these features are associated with
  • visible (bool) - whether to make property labels visible or not

_genFeatureKey(self, entry_id, feature_name)

 

Create a unique feature key.

Parameters:
  • entry_id (int) - entry id of the structure that this feature is associated with
  • feature_name - feature name
  • feature_name - str
Returns: (int, str)
tuple of (maestro entry ID, pharamcophore site name)

_getKeysForEntry(self, entry_id)

 

Get a list of all feature keys for a given entry id.

Parameters:
  • entry_id (int) - entry id of the structure that this feature is associated with
Returns: list
list of feature keys

_getEntryIDs(self)

 

Get a list of unique entry ids that feature markers stored in this mixin are associated with.

Returns: set
set of unique entry ids

getFeatureFromId(self, marker_id)

 

Return the marker with the given ID.

Parameters:
  • marker_id (int

    @return Marker object @rtype PhaseFeatureMarker

    ) - ID of the marker (.id attribute)