timeseries.visibility_graph¶
Provides classes for the analysis of dynamical systems and time series based on recurrence plots, including measures of recurrence quantification analysis (RQA) and recurrence network analysis.
-
class
pyunicorn.timeseries.visibility_graph.
VisibilityGraph
(time_series, timings=None, missing_values=False, horizontal=False, silence_level=0)[source]¶ Bases:
pyunicorn.core.interacting_networks.InteractingNetworks
Class VisibilityGraph for generating and analyzing visibility graphs of time series.
Visibility graphs were initially applied for time series analysis by [Lacasa2008].
-
__init__
(time_series, timings=None, missing_values=False, horizontal=False, silence_level=0)[source]¶ Missing values are handled as infinite values, effectively separating the visibility graph into different disconnected components.
Note
Missing values have to be marked by the Numpy NaN flag!
Parameters: - time_series (2D array (time, dimension)) – The time series to be analyzed, can be scalar or multi-dimensional.
- timings (str) – Timings of the observations in
time_series
. - missing_values (bool) – Toggle special treatment of missing values in
time_series
. - horizontal (bool) – Indicates whether a horizontal visibility relation is used.
- silence_level (number) – Inverse level of verbosity of the object.
-
advanced_betweenness
()[source]¶ Return betweenness of a node with respect to all pairs of nodes in its future.
-
advanced_local_clustering
()[source]¶ Return probability that two neighbors of a node in its future are connected.
-
boundary_corrected_closeness
()[source]¶ Return a weighted closeness corrected for trivial boundary effects.
-
boundary_corrected_degree
()[source]¶ Return a weighted degree corrected for trivial boundary effects.
-
missing_values
= None¶ Controls special treatment of missing values in
time_series
.
-
retarded_betweenness
()[source]¶ Return betweenness of a node with respect to all pairs of nodes in its past.
-
retarded_local_clustering
()[source]¶ Return probability that two neighbors of a node in its past are connected.
-
silence_level
= None¶ The inverse level of verbosity of the object.
-
time_series
= None¶ The time series from which the visibility graph is constructed.
-
timings
= None¶ The timimgs of the time series data points.
-
trans_betweenness
()[source]¶ Return betweenness of a node with respect to all pairs of nodes with one node the past and one node in the future, respectively.
-
visibility
(node1, node2)[source]¶ Returns the visibility between node 1 and 2 as boolean. :arg int node1: node index of node 1 :arg int node2: node index of node 2 :rtype: bool
-
visibility_horizontal
(node1, node2)[source]¶ Returns the horizontal visibility between node 1 and 2 as boolean. :arg int node1: node index of node 1 :arg int node2: node index of node 2 :rtype: bool
-