prolint.plotting.timeseries =========================== .. py:module:: prolint.plotting.timeseries .. autoapi-nested-parse:: Time series plotters for temporal contact visualization. This module provides time series plots for contact dynamics and distance evolution over trajectory frames. Classes ------- .. autoapisummary:: prolint.plotting.timeseries.TimeSeriesPlotter prolint.plotting.timeseries.DistanceTimeSeriesPlotter prolint.plotting.timeseries.ContactEventsPlotter Module Contents --------------- .. py:class:: TimeSeriesPlotter Bases: :py:obj:`prolint.plotting.base.BasePlotter` Plotter for contact time series. Displays contact counts over trajectory frames for multiple residues as overlaid line plots. .. seealso:: :py:obj:`TimeSeriesAnalysis` Generates time series data :py:obj:`DistanceTimeSeriesPlotter` Distance evolution plots .. py:attribute:: name :value: 'timeseries' .. py:attribute:: required_analysis :value: 'timeseries' .. py:attribute:: description :value: 'Contact counts over time for multiple residues' .. py:method:: validate_result(result: prolint.analysis.base.AnalysisResult) -> None :classmethod: Validate that result contains required time series data. .. py:method:: plot(result: prolint.analysis.base.AnalysisResult, xlabel: str = 'Frame', ylabel: str = 'Contact Count', title: str = 'Contacts Over Time', figsize: Tuple[float, float] = (10, 4), ax: Optional[matplotlib.axes.Axes] = None, time_units: Optional[str] = None, dt: float = 1.0, legend: bool = True, max_series: int = 10) -> Tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] :classmethod: Create contact count time series plot. :param result: Result from timeseries analysis. :type result: AnalysisResult :param xlabel: X-axis label. :type xlabel: str, default="Frame" :param ylabel: Y-axis label. :type ylabel: str, default="Contact Count" :param title: Plot title. :type title: str, default="Contacts Over Time" :param figsize: Figure dimensions (width, height). :type figsize: tuple of (float, float), default=(10, 4) :param ax: Existing axes to plot on. :type ax: Axes, optional :param time_units: Time unit for x-axis (e.g., "ns", "us"). :type time_units: str, optional :param dt: Time step multiplier when using time_units. :type dt: float, default=1.0 :param legend: Whether to show legend. :type legend: bool, default=True :param max_series: Maximum number of residue series to plot. :type max_series: int, default=10 :returns: Matplotlib figure and axes objects. :rtype: tuple of (Figure, Axes) .. py:class:: DistanceTimeSeriesPlotter Bases: :py:obj:`prolint.plotting.base.BasePlotter` Plotter for distance time series. Displays distance evolution between query and database residues over trajectory frames with optional cutoff line and contact highlighting. .. seealso:: :py:obj:`DistanceAnalysis` Generates distance data :py:obj:`TimeSeriesPlotter` Contact count time series .. py:attribute:: name :value: 'distance_timeseries' .. py:attribute:: required_analysis :value: 'distances' .. py:attribute:: description :value: 'Distance over time between query and database residue' .. py:method:: validate_result(result: prolint.analysis.base.AnalysisResult) -> None :classmethod: Validate that result contains required distance data. .. py:method:: plot(result: prolint.analysis.base.AnalysisResult, cutoff: Optional[float] = None, xlabel: str = 'Frame', ylabel: str = 'Distance (Å)', title: str = 'Distance Over Time', figsize: Tuple[float, float] = (12, 4), ax: Optional[matplotlib.axes.Axes] = None, time_units: Optional[str] = None, dt: float = 1.0) -> Tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] :classmethod: Create distance time series plot. :param result: Result from distances analysis. :type result: AnalysisResult :param cutoff: Distance cutoff to draw as horizontal line. :type cutoff: float, optional :param xlabel: X-axis label. :type xlabel: str, default="Frame" :param ylabel: Y-axis label. :type ylabel: str, default="Distance (Å)" :param title: Plot title. :type title: str, default="Distance Over Time" :param figsize: Figure dimensions (width, height). :type figsize: tuple of (float, float), default=(12, 4) :param ax: Existing axes to plot on. :type ax: Axes, optional :param time_units: Time unit for x-axis (e.g., "ns", "us"). :type time_units: str, optional :param dt: Time step multiplier when using time_units. :type dt: float, default=1.0 :returns: Matplotlib figure and axes objects. :rtype: tuple of (Figure, Axes) .. py:class:: ContactEventsPlotter Bases: :py:obj:`prolint.plotting.base.BasePlotter` Plotter for contact event timelines. Displays contact events as horizontal bars on a timeline, showing when contacts occur during the trajectory. .. seealso:: :py:obj:`KineticsAnalysis` Generates contact event data :py:obj:`SurvivalCurvePlotter` Survival probability curves .. py:attribute:: name :value: 'contact_events' .. py:attribute:: required_analysis :value: 'kinetics' .. py:attribute:: description :value: 'Contact events timeline showing when contacts occur' .. py:method:: validate_result(result: prolint.analysis.base.AnalysisResult) -> None :classmethod: Validate that result contains contact_frames data. .. py:method:: plot(result: prolint.analysis.base.AnalysisResult, xlabel: str = 'Frame', title: str = 'Contact Events', figsize: Tuple[float, float] = (12, 2), ax: Optional[matplotlib.axes.Axes] = None, time_units: Optional[str] = None, dt: float = 1.0) -> Tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] :classmethod: Create contact events timeline plot. :param result: Result from kinetics analysis. :type result: AnalysisResult :param xlabel: X-axis label. :type xlabel: str, default="Frame" :param title: Plot title. :type title: str, default="Contact Events" :param figsize: Figure dimensions (width, height). :type figsize: tuple of (float, float), default=(12, 2) :param ax: Existing axes to plot on. :type ax: Axes, optional :param time_units: Time unit for x-axis (e.g., "ns", "us"). :type time_units: str, optional :param dt: Time step multiplier when using time_units. :type dt: float, default=1.0 :returns: Matplotlib figure and axes objects. :rtype: tuple of (Figure, Axes)