schrodinger.ui.qt.radial_plot module¶
Widgets to plot various kinds of radial plots
- class schrodinger.ui.qt.radial_plot.Sector(ring: str, theta_0: float, theta_1: float, data: Any)¶
Bases:
object
A Sector described a specific region within a one ring of a RadianRingHistogram and that region’s associated data, if any.
- Variables
ring – the label associated with the ring the region is located in
theta_0 – the lower bound theta of the region in radians
theta_1 – the upper bound theta of the region in radians
data – any associated data with the region
- ring: str¶
- theta_0: float¶
- theta_1: float¶
- data: Any¶
- __init__(ring: str, theta_0: float, theta_1: float, data: Any) None ¶
- class schrodinger.ui.qt.radial_plot.RadialRingHistogram(figure, *args, **kwargs)¶
Bases:
PyQt6.QtCore.QObject
A RadialRingHistogram is a radial plot such that each ring, i.e each concentric circle, describes a separate histogram. Each histogram in the rings share the same x-axis namely the theta coordinates of the polar plot
Because the y-axis, i.e. the radius of the polar plot, is not used to display the frequency of the histogram data, another dimension is needed to display the frequency for example, color
- Variables
sectorClicked – emitted when a sector is clicked on by the user
- sectorClicked¶
- __init__(figure, *args, **kwargs)¶
Initialize the histogram
- Parameters
figure (smatplotlib.SmatplotlibCanvas) – the canvas to plot the figure on
- loadRingData(ring_types, ring_data)¶
Load the data for each ring and plot the histogram.
NOTE: len(ring_types) must equal len(ring_data)
- setRingTypes(ring_types)¶
Set the labels that are used for each ring in the plot. Also plot these labels at the appropraite location on the figure.
- Parameters
ring_types (List[str]) – the labels to describe each ring
- setSectorData(sector_data, sector_width)¶
Set the relevant information regarding data for each sector
- drawPlot(ring_data)¶
Plot the histograms with the data for each ring
- Parameters
ring_data – the data associated with each ring to plot a histogram for
- shouldShowSectorAnnotation(sector)¶
Whether the given sector should show an annotation
- Parameters
sector (Sector) – the sector in question
- Returns
whether to display the annotation
- Return type
bool
- getSectorAnnotation(sector)¶
Get the text that should be displayed as the annotation for the given sector
- Parameters
sector (Sector) – the sector in questions
- Returns
the annotation
- Return type
str
- getSectorAnnotationLoc(sector)¶
Get the absolute location of the annotation to be displayed for the given sector in polar coordinates
- Parameters
sector (Sector) – the sector in question
- Returns
A tuple of (radius, theta) of where the annotation should be placed
- Return type
Tuple[float, float]
- blockSignals(self, bool) bool ¶
- childEvent(self, QChildEvent)¶
- children(self) List[QObject] ¶
- connectNotify(self, QMetaMethod)¶
- customEvent(self, QEvent)¶
- deleteLater(self)¶
- destroyed¶
destroyed(self, object: QObject = None) [signal]
- disconnect(QMetaObject.Connection) bool ¶
- disconnect(self) None
- disconnectNotify(self, QMetaMethod)¶
- dumpObjectInfo(self)¶
- dumpObjectTree(self)¶
- dynamicPropertyNames(self) List[QByteArray] ¶
- event(self, QEvent) bool ¶
- eventFilter(self, QObject, QEvent) bool ¶
- findChild(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject ¶
- findChild(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObject
- findChildren(self, type, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject] ¶
- findChildren(self, Tuple, name: str = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
- findChildren(self, type, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
- findChildren(self, Tuple, QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) List[QObject]
- inherits(self, str) bool ¶
- installEventFilter(self, QObject)¶
- isSignalConnected(self, QMetaMethod) bool ¶
- isWidgetType(self) bool ¶
- isWindowType(self) bool ¶
- killTimer(self, int)¶
- metaObject(self) QMetaObject ¶
- moveToThread(self, QThread)¶
- objectName(self) str ¶
- objectNameChanged¶
objectNameChanged(self, str) [signal]
- parent(self) QObject ¶
- property(self, str) Any ¶
- pyqtConfigure(...)¶
Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.
- receivers(self, PYQT_SIGNAL) int ¶
- removeEventFilter(self, QObject)¶
- sender(self) QObject ¶
- senderSignalIndex(self) int ¶
- setObjectName(self, str)¶
- setParent(self, QObject)¶
- setProperty(self, str, Any) bool ¶
- signalsBlocked(self) bool ¶
- startTimer(self, int, timerType: Qt.TimerType = Qt.CoarseTimer) int ¶
- staticMetaObject = <PyQt6.QtCore.QMetaObject object>¶
- thread(self) QThread ¶
- timerEvent(self, QTimerEvent)¶
- tr(str, disambiguation: str = None, n: int = - 1) str ¶