MCPcopy Index your code
hub / github.com/DynamicTimeWarping/dtw-python / plot

Method plot

dtw/dtw.py:82–124  ·  view source on GitHub ↗

Plotting of dynamic time warp results Methods for plotting dynamic time warp alignment objects returned by [dtw()]. **Details** ``dtwPlot`` displays alignment contained in ``dtw`` objects. Various plotting styles are available, passing strings to the ``type`` argument (may be abbreviated): - ``

(self, type="alignment", **kwargs)

Source from the content-addressed store, hash-verified

80 return (s)
81
82 def plot(self, type="alignment", **kwargs):
83 # IMPORT_RDOCSTRING plot.dtw
84 """Plotting of dynamic time warp results
85
86Methods for plotting dynamic time warp alignment objects returned by
87[dtw()].
88
89**Details**
90
91``dtwPlot`` displays alignment contained in ``dtw`` objects.
92
93Various plotting styles are available, passing strings to the ``type``
94argument (may be abbreviated):
95
96- ``alignment`` plots the warping curve in ``d``;
97- ``twoway`` plots a point-by-point comparison, with matching lines; see
98 [dtwPlotTwoWay()];
99- ``threeway`` vis-a-vis inspection of the timeseries and their warping
100 curve; see [dtwPlotThreeWay()];
101- ``density`` displays the cumulative cost landscape with the warping
102 path overimposed; see [dtwPlotDensity()]
103
104Additional parameters are passed to the plotting functions: use with
105care.
106
107Parameters
108----------
109x,d :
110 `dtw` object, usually result of call to [dtw()]
111xlab :
112 label for the query axis
113ylab :
114 label for the reference axis
115type :
116 general style for the plot, see below
117plot_type :
118 type of line to be drawn, used as the `type` argument in the underlying `plot` call
119... :
120 additional arguments, passed to plotting functions
121
122"""
123 # ENDIMPORT
124 return dtwPlot(self, type, **kwargs)
125
126
127# --------------------

Callers 9

dtwPlotAlignmentFunction · 0.45
dtwPlotTwoWayFunction · 0.45
dtwPlotThreeWayFunction · 0.45
dtwPlotDensityFunction · 0.45
test_plot_threewayMethod · 0.45
test_plot_twowayMethod · 0.45

Calls 1

dtwPlotFunction · 0.85

Tested by 4

test_plot_threewayMethod · 0.36
test_plot_twowayMethod · 0.36