diplotocus 0.6.3__tar.gz → 0.6.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {diplotocus-0.6.3 → diplotocus-0.6.5}/PKG-INFO +1 -1
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/api/core.rst +60 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/GUI.ipynb +1 -1
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/plot_objects.ipynb +1 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/quick-start.ipynb +6 -6
- diplotocus-0.6.5/src/diplotocus/_version.py +1 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/animations.py +221 -80
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus.egg-info/PKG-INFO +1 -1
- diplotocus-0.6.3/src/diplotocus/_version.py +0 -1
- {diplotocus-0.6.3 → diplotocus-0.6.5}/.gitattributes +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/.gitignore +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/.readthedocs.yaml +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/LICENSE +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/Makefile +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/_static/force-light.css +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/_static/force-light.js +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/make.bat +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/requirements.txt +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/Web_GUI.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/button.svg +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/demo.mp4 +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/favicon.ico +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/force-light.css +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/force-light.js +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/logo.mp4 +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/_static/logo.svg +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/api/index.rst +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/conf.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/index.rst +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/animations.ipynb +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/easings.ipynb +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/index.ipynb +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/installation.ipynb +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/docs/source/notebooks/timeline.ipynb +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/logo.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/pyproject.toml +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/readme.md +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/setup.cfg +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/GUI.html +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/__init__.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/app.js +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/server.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/bg.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_Draw.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_Morph.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_Rotate.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_Scale.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_Sequence.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_Translate.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_Tween.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/btn/btn_bg_default.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/favicon.ico +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/src/logo_bg.png +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/GUI/style.css +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/__init__.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/core.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus/easings.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus.egg-info/SOURCES.txt +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus.egg-info/dependency_links.txt +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus.egg-info/requires.txt +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/src/diplotocus.egg-info/top_level.txt +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test10.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test2.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test3.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test4.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test5.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test6.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test7.py +0 -0
- {diplotocus-0.6.3 → diplotocus-0.6.5}/tests/test8.py +0 -0
|
@@ -31,10 +31,18 @@ Axis and figure animations
|
|
|
31
31
|
:members:
|
|
32
32
|
:undoc-members:
|
|
33
33
|
|
|
34
|
+
.. autoclass:: diplotocus.animations.axis_pos_and_size
|
|
35
|
+
:members:
|
|
36
|
+
:undoc-members:
|
|
37
|
+
|
|
34
38
|
.. autoclass:: diplotocus.animations.axis_move
|
|
35
39
|
:members:
|
|
36
40
|
:undoc-members:
|
|
37
41
|
|
|
42
|
+
.. autoclass:: diplotocus.animations.axis_track
|
|
43
|
+
:members:
|
|
44
|
+
:undoc-members:
|
|
45
|
+
|
|
38
46
|
.. autoclass:: diplotocus.animations.axis_alpha
|
|
39
47
|
:members:
|
|
40
48
|
:undoc-members:
|
|
@@ -102,6 +110,58 @@ Plot object animations
|
|
|
102
110
|
:members:
|
|
103
111
|
:undoc-members:
|
|
104
112
|
|
|
113
|
+
.. autoclass:: diplotocus.animations.Circle
|
|
114
|
+
:members:
|
|
115
|
+
:undoc-members:
|
|
116
|
+
|
|
117
|
+
.. autoclass:: diplotocus.animations.fill
|
|
118
|
+
:members:
|
|
119
|
+
:undoc-members:
|
|
120
|
+
|
|
121
|
+
.. autoclass:: diplotocus.animations.Annulus
|
|
122
|
+
:members:
|
|
123
|
+
:undoc-members:
|
|
124
|
+
|
|
125
|
+
.. autoclass:: diplotocus.animations.Arc
|
|
126
|
+
:members:
|
|
127
|
+
:undoc-members:
|
|
128
|
+
|
|
129
|
+
.. autoclass:: diplotocus.animations.Arrow
|
|
130
|
+
:members:
|
|
131
|
+
:undoc-members:
|
|
132
|
+
|
|
133
|
+
.. autoclass:: diplotocus.animations.Ellipse
|
|
134
|
+
:members:
|
|
135
|
+
:undoc-members:
|
|
136
|
+
|
|
137
|
+
.. autoclass:: diplotocus.animations.FancyArrow
|
|
138
|
+
:members:
|
|
139
|
+
:undoc-members:
|
|
140
|
+
|
|
141
|
+
.. autoclass:: diplotocus.animations.Polygon
|
|
142
|
+
:members:
|
|
143
|
+
:undoc-members:
|
|
144
|
+
|
|
145
|
+
.. autoclass:: diplotocus.animations.Rectangle
|
|
146
|
+
:members:
|
|
147
|
+
:undoc-members:
|
|
148
|
+
|
|
149
|
+
.. autoclass:: diplotocus.animations.RegularPolygon
|
|
150
|
+
:members:
|
|
151
|
+
:undoc-members:
|
|
152
|
+
|
|
153
|
+
.. autoclass:: diplotocus.animations.Wedge
|
|
154
|
+
:members:
|
|
155
|
+
:undoc-members:
|
|
156
|
+
|
|
157
|
+
.. autoclass:: diplotocus.animations.bar
|
|
158
|
+
:members:
|
|
159
|
+
:undoc-members:
|
|
160
|
+
|
|
161
|
+
.. autoclass:: diplotocus.animations.ConnectionPatch
|
|
162
|
+
:members:
|
|
163
|
+
:undoc-members:
|
|
164
|
+
|
|
105
165
|
Easings
|
|
106
166
|
-------
|
|
107
167
|
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"The GUI might not be as stable as the python interface and is currently lacking recently added features. Feel free to report any issues you encounter or features you want to see be added in priority.\n",
|
|
17
17
|
"```\n",
|
|
18
18
|
"\n",
|
|
19
|
-
"When running diplotocus through this mode, you will
|
|
19
|
+
"When running diplotocus through this mode, you will edit your animation through a local web page in your browser. This page communicates with a python server, which links the GUI and diplotocus objects in the background. Hence, everything you can do through python, you can do through the GUI, and vice versa.\n",
|
|
20
20
|
"\n",
|
|
21
21
|
"```{note}\n",
|
|
22
22
|
"\n",
|
|
@@ -10,10 +10,10 @@
|
|
|
10
10
|
"This page will guide you through the syntax and feature of Diplotocus.\n",
|
|
11
11
|
"\n",
|
|
12
12
|
"First, here are a few terms we will be using:\n",
|
|
13
|
-
"- a
|
|
14
|
-
"- a
|
|
15
|
-
"- an
|
|
16
|
-
"- an
|
|
13
|
+
"- a *Timeline* is the main object of a project. It holds the figure, axes, and is responsible for running animations and rendering the video (See [Timeline](timeline) for more information).\n",
|
|
14
|
+
"- a *plot object* is any matplotlib plotting function you are familiar with: `plot()`, `scatter()`, `hist()`, `text()`... (See [Plot objects](plot_objects) for more information).\n",
|
|
15
|
+
"- an *animation* is what is applied to `plot objects` to animate it: `translate()`,`rotate()`,`tween`... (See [Animations](animations) for more information).\n",
|
|
16
|
+
"- an *easing* is a mapping between frame number and time, that might not be linear ({doc}`See Easings <easings>` for more information).\n",
|
|
17
17
|
"\n",
|
|
18
18
|
"The basic steps involved in creating animations are the following:\n",
|
|
19
19
|
"1. Create a `Timeline` object. Optionally, you can give it an existing figure, or define its initial properties.\n",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"\n",
|
|
27
27
|
"Let's go through the example on the main page step by step:\n",
|
|
28
28
|
"\n",
|
|
29
|
-
"First, we import our modules. By convention, we import diplotocus as dpl
|
|
29
|
+
"First, we import our modules. By convention, we `import diplotocus as dpl`, *à la* `import matplotlib.pyplot as plt`."
|
|
30
30
|
]
|
|
31
31
|
},
|
|
32
32
|
{
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
"id": "92f889da",
|
|
139
139
|
"metadata": {},
|
|
140
140
|
"source": [
|
|
141
|
-
"
|
|
141
|
+
"Now we want to animate our axis, by zooming out and moving its center to (0,0), simultaneously. We define our two animations, `axis_zoom` and `axis_move`, and we animate them through our `Timeline`."
|
|
142
142
|
]
|
|
143
143
|
},
|
|
144
144
|
{
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.6.5"
|
|
@@ -27,7 +27,12 @@ def dealias(mpl_obj,kwargs):
|
|
|
27
27
|
return kwargs
|
|
28
28
|
|
|
29
29
|
def to_np_array(obj):
|
|
30
|
-
obj
|
|
30
|
+
if type(obj) == np.ndarray:
|
|
31
|
+
return obj
|
|
32
|
+
try:
|
|
33
|
+
obj = np.array(obj)
|
|
34
|
+
except:
|
|
35
|
+
obj = np.array(obj,dtype=object)
|
|
31
36
|
if obj.ndim == 0:
|
|
32
37
|
obj = np.ravel(obj)
|
|
33
38
|
return obj
|
|
@@ -148,6 +153,8 @@ class plotObject:
|
|
|
148
153
|
if idx is None:
|
|
149
154
|
kwargs[key] = to_np_array([])
|
|
150
155
|
else:
|
|
156
|
+
if isinstance(idx,(list,np.ndarray)):
|
|
157
|
+
idx = [i for i in idx if i < len(kwarg)]
|
|
151
158
|
kwargs[key] = to_np_array(kwarg)[idx]
|
|
152
159
|
return kwargs
|
|
153
160
|
|
|
@@ -157,10 +164,10 @@ class plotObject:
|
|
|
157
164
|
|
|
158
165
|
i_min,i_max = -1,-1
|
|
159
166
|
|
|
160
|
-
if 'alpha' in kwargs:
|
|
161
|
-
alpha = to_np_array(kwargs['alpha'])
|
|
162
|
-
if np.sum(alpha) == 0:
|
|
163
|
-
kwargs['alpha'] = 1
|
|
167
|
+
#if 'alpha' in kwargs:
|
|
168
|
+
#alpha = to_np_array(kwargs['alpha'])
|
|
169
|
+
#if np.sum(alpha) == 0:
|
|
170
|
+
#kwargs['alpha'] = 1
|
|
164
171
|
|
|
165
172
|
for anim in self.anims:
|
|
166
173
|
if anim['name'] != 'sample':
|
|
@@ -170,10 +177,6 @@ class plotObject:
|
|
|
170
177
|
if x < anim['delay'] or x > anim['delay'] + anim['duration']:
|
|
171
178
|
continue
|
|
172
179
|
|
|
173
|
-
#if len(data_x.shape) == 1:
|
|
174
|
-
#data_x = data_x.reshape((-1,1))
|
|
175
|
-
#data_y = data_y.reshape((-1,1))
|
|
176
|
-
|
|
177
180
|
i_min,i_max = self.get_i_min_i_max_sample(anim,x,len(data_x))
|
|
178
181
|
break
|
|
179
182
|
|
|
@@ -181,9 +184,13 @@ class plotObject:
|
|
|
181
184
|
data_x = data_x[i_min:i_max]
|
|
182
185
|
if data_y is not None:
|
|
183
186
|
data_y = data_y[i_min:i_max]
|
|
187
|
+
if data_x.shape[0] == 1:
|
|
188
|
+
data_x = data_x.reshape(-1)
|
|
189
|
+
if data_y.shape[0] == 1:
|
|
190
|
+
data_y = data_y.reshape(-1)
|
|
184
191
|
kwargs = self.resize_kwargs(kwargs,list(range(i_min,i_max)))
|
|
185
192
|
|
|
186
|
-
#
|
|
193
|
+
#Second pass to morph
|
|
187
194
|
for anim in self.anims:
|
|
188
195
|
if anim['name'] != 'morph':
|
|
189
196
|
continue
|
|
@@ -204,7 +211,7 @@ class plotObject:
|
|
|
204
211
|
else:
|
|
205
212
|
_t = t
|
|
206
213
|
new_data_x.append(data_x[i] + (anim['new_x'][i] - data_x[i])*_t)
|
|
207
|
-
if len(data_y) == len(
|
|
214
|
+
if len(data_y) == len(data_x):
|
|
208
215
|
new_data_y.append(data_y[i] + (anim['new_y'][i] - data_y[i])*_t)
|
|
209
216
|
data_x = new_data_x
|
|
210
217
|
data_y = new_data_y
|
|
@@ -275,13 +282,13 @@ class plotObject:
|
|
|
275
282
|
i_min = int((_x + anim['min'])/anim['duration']*len_data)
|
|
276
283
|
i_min = max(i_min,0)
|
|
277
284
|
if type(anim['max']) == str and anim['max'] == 'end':
|
|
278
|
-
i_max = len_data
|
|
285
|
+
i_max = len_data+1
|
|
279
286
|
else:
|
|
280
287
|
if anim['max'] == anim['min']:
|
|
281
288
|
i_max = i_min + 1
|
|
282
289
|
else:
|
|
283
|
-
i_max = int((_x + anim['max'])/anim['duration']*len_data)
|
|
284
|
-
i_max = min(i_max,len_data
|
|
290
|
+
i_max = int((_x + anim['max'])/(anim['duration']-1)*(len_data+1))
|
|
291
|
+
i_max = min(i_max,len_data+1)
|
|
285
292
|
return i_min,i_max
|
|
286
293
|
|
|
287
294
|
def get_sequential_t(self,i,x,size,anim):
|
|
@@ -1133,7 +1140,7 @@ class axis_pos_and_size(plotObject):
|
|
|
1133
1140
|
Target width
|
|
1134
1141
|
end_height : float
|
|
1135
1142
|
Target height
|
|
1136
|
-
start_left
|
|
1143
|
+
start_left : float
|
|
1137
1144
|
Initial left position
|
|
1138
1145
|
start_bottom : float
|
|
1139
1146
|
Initial bottom position
|
|
@@ -1141,10 +1148,6 @@ class axis_pos_and_size(plotObject):
|
|
|
1141
1148
|
Initial width
|
|
1142
1149
|
start_height : float
|
|
1143
1150
|
Initial height
|
|
1144
|
-
pos : array-like
|
|
1145
|
-
Target left and bottom position
|
|
1146
|
-
size : array-like
|
|
1147
|
-
Target width and height
|
|
1148
1151
|
duration : float
|
|
1149
1152
|
Duration of the animation
|
|
1150
1153
|
delay : float, default=0
|
|
@@ -1195,9 +1198,8 @@ class axis_pos_and_size(plotObject):
|
|
|
1195
1198
|
|
|
1196
1199
|
def function(self,data_x,data_y,x,kwargs):
|
|
1197
1200
|
anim = self.anims[0]
|
|
1198
|
-
if x < anim['delay']:
|
|
1201
|
+
if x < anim['delay'] or x >= anim['delay'] + anim['duration']:
|
|
1199
1202
|
return
|
|
1200
|
-
_x = min(x,anim['duration'] + anim['delay']-1)
|
|
1201
1203
|
t = self.get_t_from_x(anim,x)
|
|
1202
1204
|
width = self.axis.get_xlim()[1]-self.axis.get_xlim()[0]
|
|
1203
1205
|
height = self.axis.get_ylim()[1]-self.axis.get_ylim()[0]
|
|
@@ -1412,11 +1414,9 @@ class fig_width_ratio(plotObject):
|
|
|
1412
1414
|
Delay before starting
|
|
1413
1415
|
easing : callable, optional
|
|
1414
1416
|
Easing function
|
|
1415
|
-
axis : matplotlib.axes.Axes, optional
|
|
1416
|
-
Axis to plot on
|
|
1417
1417
|
"""
|
|
1418
|
-
def __init__(self,start_widths,end_widths,duration,delay=0,easing=None
|
|
1419
|
-
super().__init__(
|
|
1418
|
+
def __init__(self,start_widths,end_widths,duration,delay=0,easing=None,*args,**kwargs):
|
|
1419
|
+
super().__init__(*args, **kwargs)
|
|
1420
1420
|
self.grid = None
|
|
1421
1421
|
start_widths = to_np_array(start_widths).astype(float)
|
|
1422
1422
|
end_widths = to_np_array(end_widths).astype(float)
|
|
@@ -1483,11 +1483,9 @@ class fig_height_ratio(plotObject):
|
|
|
1483
1483
|
Delay before starting
|
|
1484
1484
|
easing : callable, optional
|
|
1485
1485
|
Easing function
|
|
1486
|
-
axis : matplotlib.axes.Axes, optional
|
|
1487
|
-
Axis to plot on
|
|
1488
1486
|
"""
|
|
1489
|
-
def __init__(self,start_heights,end_heights,duration,delay=0,easing=None
|
|
1490
|
-
super().__init__(
|
|
1487
|
+
def __init__(self,start_heights,end_heights,duration,delay=0,easing=None,*args,**kwargs):
|
|
1488
|
+
super().__init__(*args, **kwargs)
|
|
1491
1489
|
self.grid = None
|
|
1492
1490
|
start_heights = to_np_array(start_heights)
|
|
1493
1491
|
end_heights = to_np_array(end_heights)
|
|
@@ -1547,10 +1545,6 @@ class scatter(plotObject):
|
|
|
1547
1545
|
x, y : float or array-like, shape (n, )
|
|
1548
1546
|
The data positions.
|
|
1549
1547
|
|
|
1550
|
-
duration : float
|
|
1551
|
-
Duration of the animation
|
|
1552
|
-
delay : float, default=0
|
|
1553
|
-
Delay before starting
|
|
1554
1548
|
easing : callable, optional
|
|
1555
1549
|
Easing function
|
|
1556
1550
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -1861,10 +1855,6 @@ class plot(plotObject):
|
|
|
1861
1855
|
The horizontal / vertical coordinates of the data points.
|
|
1862
1856
|
*x* values are optional and default to ``range(len(y))``.
|
|
1863
1857
|
|
|
1864
|
-
duration : float
|
|
1865
|
-
Duration of the animation
|
|
1866
|
-
delay : float, default=0
|
|
1867
|
-
Delay before starting
|
|
1868
1858
|
easing : callable, optional
|
|
1869
1859
|
Easing function
|
|
1870
1860
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -2074,7 +2064,6 @@ class plot(plotObject):
|
|
|
2074
2064
|
self.mpl_obj_type = mpl.lines.Line2D
|
|
2075
2065
|
self.mpl_plot_type = plt.plot
|
|
2076
2066
|
super().__init__(easing=easing,axis=axis,*args, **kwargs)
|
|
2077
|
-
|
|
2078
2067
|
self.x = to_np_array(x)
|
|
2079
2068
|
self.y = to_np_array(y)
|
|
2080
2069
|
if self.x.size != self.y.size:
|
|
@@ -2083,6 +2072,7 @@ class plot(plotObject):
|
|
|
2083
2072
|
def function(self,data_x,data_y,x,kwargs):
|
|
2084
2073
|
if 'alpha' in kwargs and isinstance(kwargs['alpha'],np.ndarray):
|
|
2085
2074
|
kwargs['alpha'] = kwargs['alpha'][0]
|
|
2075
|
+
|
|
2086
2076
|
self.obj = self.axis.plot(data_x,data_y,**kwargs)
|
|
2087
2077
|
|
|
2088
2078
|
class step(plotObject):
|
|
@@ -2116,6 +2106,11 @@ class step(plotObject):
|
|
|
2116
2106
|
y : array-like
|
|
2117
2107
|
1D sequence of y levels.
|
|
2118
2108
|
|
|
2109
|
+
easing : callable, optional
|
|
2110
|
+
Easing function
|
|
2111
|
+
axis : matplotlib.axes.Axes, optional
|
|
2112
|
+
Axis to plot on
|
|
2113
|
+
|
|
2119
2114
|
fmt : str, optional
|
|
2120
2115
|
A format string, e.g. 'g' for a green line. See `.plot` for a more
|
|
2121
2116
|
detailed description.
|
|
@@ -2184,10 +2179,6 @@ class fill_between(plotObject):
|
|
|
2184
2179
|
x : array-like
|
|
2185
2180
|
The x coordinates of the nodes defining the curves.
|
|
2186
2181
|
|
|
2187
|
-
duration : float
|
|
2188
|
-
Duration of the animation
|
|
2189
|
-
delay : float, default=0
|
|
2190
|
-
Delay before starting
|
|
2191
2182
|
easing : callable, optional
|
|
2192
2183
|
Easing function
|
|
2193
2184
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -2382,10 +2373,6 @@ class fill_betweenx(plotObject):
|
|
|
2382
2373
|
y : array-like
|
|
2383
2374
|
The y coordinates of the nodes defining the curves.
|
|
2384
2375
|
|
|
2385
|
-
duration : float
|
|
2386
|
-
Duration of the animation
|
|
2387
|
-
delay : float, default=0
|
|
2388
|
-
Delay before starting
|
|
2389
2376
|
easing : callable, optional
|
|
2390
2377
|
Easing function
|
|
2391
2378
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -2573,10 +2560,6 @@ class axvline(plotObject):
|
|
|
2573
2560
|
x : float, default: 0
|
|
2574
2561
|
x position in :ref:`data coordinates <coordinate-systems>`.
|
|
2575
2562
|
|
|
2576
|
-
duration : float
|
|
2577
|
-
Duration of the animation
|
|
2578
|
-
delay : float, default=0
|
|
2579
|
-
Delay before starting
|
|
2580
2563
|
easing : callable, optional
|
|
2581
2564
|
Easing function
|
|
2582
2565
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -2712,6 +2695,11 @@ class axhline(plotObject):
|
|
|
2712
2695
|
y : float, default: 0
|
|
2713
2696
|
y position in :ref:`data coordinates <coordinate-systems>`.
|
|
2714
2697
|
|
|
2698
|
+
easing : callable, optional
|
|
2699
|
+
Easing function
|
|
2700
|
+
axis : matplotlib.axes.Axes, optional
|
|
2701
|
+
Axis to plot on
|
|
2702
|
+
|
|
2715
2703
|
xmin : float, default: 0
|
|
2716
2704
|
The start x-position in :ref:`axes coordinates <coordinate-systems>`.
|
|
2717
2705
|
Should be between 0 and 1, 0 being the far left of the plot,
|
|
@@ -2795,10 +2783,6 @@ class errorbar(plotObject):
|
|
|
2795
2783
|
x, y : float or array-like
|
|
2796
2784
|
The data positions.
|
|
2797
2785
|
|
|
2798
|
-
duration : float
|
|
2799
|
-
Duration of the animation
|
|
2800
|
-
delay : float, default=0
|
|
2801
|
-
Delay before starting
|
|
2802
2786
|
easing : callable, optional
|
|
2803
2787
|
Easing function
|
|
2804
2788
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -3055,10 +3039,6 @@ class hist(plotObject):
|
|
|
3055
3039
|
Input values, this takes either a single array or a sequence of
|
|
3056
3040
|
arrays which are not required to be of the same length.
|
|
3057
3041
|
|
|
3058
|
-
duration : float
|
|
3059
|
-
Duration of the animation
|
|
3060
|
-
delay : float, default=0
|
|
3061
|
-
Delay before starting
|
|
3062
3042
|
easing : callable, optional
|
|
3063
3043
|
Easing function
|
|
3064
3044
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -3285,10 +3265,6 @@ class hist2d(plotObject):
|
|
|
3285
3265
|
x, y : array-like, shape (n, )
|
|
3286
3266
|
Input values
|
|
3287
3267
|
|
|
3288
|
-
duration : float
|
|
3289
|
-
Duration of the animation
|
|
3290
|
-
delay : float, default=0
|
|
3291
|
-
Delay before starting
|
|
3292
3268
|
easing : callable, optional
|
|
3293
3269
|
Easing function
|
|
3294
3270
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -3455,10 +3431,6 @@ class contourf(plotObject):
|
|
|
3455
3431
|
X, Y : array-like, optional
|
|
3456
3432
|
The coordinates of the values in *Z*.
|
|
3457
3433
|
|
|
3458
|
-
duration : float
|
|
3459
|
-
Duration of the animation
|
|
3460
|
-
delay : float, default=0
|
|
3461
|
-
Delay before starting
|
|
3462
3434
|
easing : callable, optional
|
|
3463
3435
|
Easing function
|
|
3464
3436
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -3818,10 +3790,6 @@ class text(plotObject):
|
|
|
3818
3790
|
|
|
3819
3791
|
A dictionary to override the default text properties. If fontdict
|
|
3820
3792
|
is None, the defaults are determined by `.rcParams`.
|
|
3821
|
-
duration : float
|
|
3822
|
-
Duration of the animation
|
|
3823
|
-
delay : float, default=0
|
|
3824
|
-
Delay before starting
|
|
3825
3793
|
easing : callable, optional
|
|
3826
3794
|
Easing function
|
|
3827
3795
|
axis : matplotlib.axes.Axes, optional
|
|
@@ -4053,6 +4021,10 @@ class svg(plotObject):
|
|
|
4053
4021
|
the edge color.
|
|
4054
4022
|
lw : float, default=2
|
|
4055
4023
|
the line width.
|
|
4024
|
+
easing : callable, optional
|
|
4025
|
+
Easing function
|
|
4026
|
+
axis : matplotlib.axes.Axes, optional
|
|
4027
|
+
Axis to plot on
|
|
4056
4028
|
"""
|
|
4057
4029
|
def __init__(self, data, fc=None, ec='k', lw=2,easing=None,axis=None, *args, **kwargs):
|
|
4058
4030
|
self.mpl_obj_type = mpl.patches.PathPatch
|
|
@@ -4125,6 +4097,17 @@ class Circle(plotObject):
|
|
|
4125
4097
|
|
|
4126
4098
|
Create a true circle at center *xy* = (*x*, *y*) with given *radius*.
|
|
4127
4099
|
|
|
4100
|
+
Parameters
|
|
4101
|
+
----------
|
|
4102
|
+
xy : (float, float)
|
|
4103
|
+
xy coordinates of circle centre.
|
|
4104
|
+
r : float
|
|
4105
|
+
The radius
|
|
4106
|
+
easing : callable, optional
|
|
4107
|
+
Easing function
|
|
4108
|
+
axis : matplotlib.axes.Axes, optional
|
|
4109
|
+
Axis to plot on
|
|
4110
|
+
|
|
4128
4111
|
Unlike `CirclePolygon` which is a polygonal approximation, this uses
|
|
4129
4112
|
Bezier splines and is much closer to a scale-free circle.
|
|
4130
4113
|
"""
|
|
@@ -4174,6 +4157,11 @@ class fill(plotObject):
|
|
|
4174
4157
|
ax.fill("time", "signal",
|
|
4175
4158
|
data={"time": [0, 1, 2], "signal": [0, 1, 0]})
|
|
4176
4159
|
|
|
4160
|
+
easing : callable, optional
|
|
4161
|
+
Easing function
|
|
4162
|
+
axis : matplotlib.axes.Axes, optional
|
|
4163
|
+
Axis to plot on
|
|
4164
|
+
|
|
4177
4165
|
Returns
|
|
4178
4166
|
-------
|
|
4179
4167
|
list of `~matplotlib.patches.Polygon`
|
|
@@ -4223,6 +4211,10 @@ class Annulus(plotObject):
|
|
|
4223
4211
|
angle : float, default: 0
|
|
4224
4212
|
Rotation angle in degrees (anti-clockwise from the positive
|
|
4225
4213
|
x-axis). Ignored for circular annuli (i.e., if *r* is a scalar).
|
|
4214
|
+
easing : callable, optional
|
|
4215
|
+
Easing function
|
|
4216
|
+
axis : matplotlib.axes.Axes, optional
|
|
4217
|
+
Axis to plot on
|
|
4226
4218
|
"""
|
|
4227
4219
|
def __init__(self,xy,r,width,angle=0.0,easing=None,axis=None, *args, **kwargs):
|
|
4228
4220
|
self.mpl_obj_type = mpl.patches.Circle
|
|
@@ -4271,6 +4263,12 @@ class Arc(plotObject):
|
|
|
4271
4263
|
represented by an equivalent angle in the range [0, 360), by
|
|
4272
4264
|
taking the input value mod 360.
|
|
4273
4265
|
|
|
4266
|
+
easing : callable, optional
|
|
4267
|
+
Easing function
|
|
4268
|
+
|
|
4269
|
+
axis : matplotlib.axes.Axes, optional
|
|
4270
|
+
Axis to plot on
|
|
4271
|
+
|
|
4274
4272
|
Other Parameters
|
|
4275
4273
|
----------------
|
|
4276
4274
|
**kwargs : `~matplotlib.patches.Patch` properties
|
|
@@ -4322,6 +4320,10 @@ class Arrow(plotObject):
|
|
|
4322
4320
|
width : float, default: 1
|
|
4323
4321
|
Scale factor for the width of the arrow. With a default value of 1,
|
|
4324
4322
|
the tail width is 0.2 and head width is 0.6.
|
|
4323
|
+
easing : callable, optional
|
|
4324
|
+
Easing function
|
|
4325
|
+
axis : matplotlib.axes.Axes, optional
|
|
4326
|
+
Axis to plot on
|
|
4325
4327
|
**kwargs
|
|
4326
4328
|
Keyword arguments control the `Patch` properties:
|
|
4327
4329
|
|
|
@@ -4365,6 +4367,10 @@ class Ellipse(plotObject):
|
|
|
4365
4367
|
Total length (diameter) of vertical axis.
|
|
4366
4368
|
angle : float, default: 0
|
|
4367
4369
|
Rotation in degrees anti-clockwise.
|
|
4370
|
+
easing : callable, optional
|
|
4371
|
+
Easing function
|
|
4372
|
+
axis : matplotlib.axes.Axes, optional
|
|
4373
|
+
Axis to plot on
|
|
4368
4374
|
"""
|
|
4369
4375
|
def __init__(self,xy,width,height,angle=0,easing=None,axis=None, *args, **kwargs):
|
|
4370
4376
|
self.mpl_obj_type = mpl.patches.Ellipse
|
|
@@ -4417,6 +4423,12 @@ class FancyArrow(plotObject):
|
|
|
4417
4423
|
head_starts_at_zero : bool, default: False
|
|
4418
4424
|
If True, the head starts being drawn at coordinate 0
|
|
4419
4425
|
instead of ending at coordinate 0.
|
|
4426
|
+
|
|
4427
|
+
easing : callable, optional
|
|
4428
|
+
Easing function
|
|
4429
|
+
|
|
4430
|
+
axis : matplotlib.axes.Axes, optional
|
|
4431
|
+
Axis to plot on
|
|
4420
4432
|
"""
|
|
4421
4433
|
def __init__(self,x,y,dx,dy,width=0.001,
|
|
4422
4434
|
length_includes_head=False,head_width=None,head_length=None,
|
|
@@ -4463,6 +4475,12 @@ class Polygon(plotObject):
|
|
|
4463
4475
|
closed : bool, default: True
|
|
4464
4476
|
Whether the polygon is closed (i.e., has identical start and end
|
|
4465
4477
|
points).
|
|
4478
|
+
|
|
4479
|
+
easing : callable, optional
|
|
4480
|
+
Easing function
|
|
4481
|
+
|
|
4482
|
+
axis : matplotlib.axes.Axes, optional
|
|
4483
|
+
Axis to plot on
|
|
4466
4484
|
"""
|
|
4467
4485
|
def __init__(self,xy,closed=True,easing=None,axis=None, *args, **kwargs):
|
|
4468
4486
|
self.mpl_obj_type = mpl.patches.Polygon
|
|
@@ -4511,6 +4529,10 @@ class Rectangle(plotObject):
|
|
|
4511
4529
|
If ``'xy'``, rotate around the anchor point. If ``'center'`` rotate
|
|
4512
4530
|
around the center. If 2-tuple of number, rotate around this
|
|
4513
4531
|
coordinate.
|
|
4532
|
+
easing : callable, optional
|
|
4533
|
+
Easing function
|
|
4534
|
+
axis : matplotlib.axes.Axes, optional
|
|
4535
|
+
Axis to plot on
|
|
4514
4536
|
"""
|
|
4515
4537
|
def __init__(self,xy,width,height,angle=0.0,rotation_point='xy',easing=None,axis=None, *args, **kwargs):
|
|
4516
4538
|
self.mpl_obj_type = mpl.patches.Rectangle
|
|
@@ -4552,6 +4574,12 @@ class RegularPolygon(plotObject):
|
|
|
4552
4574
|
|
|
4553
4575
|
orientation : float
|
|
4554
4576
|
The polygon rotation angle (in radians).
|
|
4577
|
+
|
|
4578
|
+
easing : callable, optional
|
|
4579
|
+
Easing function
|
|
4580
|
+
|
|
4581
|
+
axis : matplotlib.axes.Axes, optional
|
|
4582
|
+
Axis to plot on
|
|
4555
4583
|
"""
|
|
4556
4584
|
def __init__(self,xy,numVertices,radius=5,orientation=0,easing=None,axis=None, *args, **kwargs):
|
|
4557
4585
|
self.mpl_obj_type = mpl.patches.RegularPolygon
|
|
@@ -4578,6 +4606,23 @@ class Wedge(plotObject):
|
|
|
4578
4606
|
"""
|
|
4579
4607
|
Wedge shaped patch.
|
|
4580
4608
|
|
|
4609
|
+
Parameters
|
|
4610
|
+
----------
|
|
4611
|
+
center : (float,float)
|
|
4612
|
+
The center of the wedge
|
|
4613
|
+
r : float
|
|
4614
|
+
The radius of the wedge
|
|
4615
|
+
theta1 : float
|
|
4616
|
+
The first angle (in degrees) of the wedge
|
|
4617
|
+
theta2 : float
|
|
4618
|
+
The second angle (in degrees) of the wedge
|
|
4619
|
+
width : float, optional
|
|
4620
|
+
The width of the partial wedge
|
|
4621
|
+
easing : callable, optional
|
|
4622
|
+
Easing function
|
|
4623
|
+
axis : matplotlib.axes.Axes, optional
|
|
4624
|
+
Axis to plot on
|
|
4625
|
+
|
|
4581
4626
|
A wedge centered at *x*, *y* center with radius *r* that
|
|
4582
4627
|
sweeps *theta1* to *theta2* (in degrees). If *width* is given,
|
|
4583
4628
|
then a partial wedge is drawn from inner radius *r* - *width*
|
|
@@ -4661,6 +4706,12 @@ class bar(plotObject):
|
|
|
4661
4706
|
To align the bars on the right edge pass a negative *width* and
|
|
4662
4707
|
``align='edge'``.
|
|
4663
4708
|
|
|
4709
|
+
easing : callable, optional
|
|
4710
|
+
Easing function
|
|
4711
|
+
|
|
4712
|
+
axis : matplotlib.axes.Axes, optional
|
|
4713
|
+
Axis to plot on
|
|
4714
|
+
|
|
4664
4715
|
Returns
|
|
4665
4716
|
-------
|
|
4666
4717
|
`.BarContainer`
|
|
@@ -4668,15 +4719,15 @@ class bar(plotObject):
|
|
|
4668
4719
|
|
|
4669
4720
|
Other Parameters
|
|
4670
4721
|
----------------
|
|
4671
|
-
color :
|
|
4722
|
+
color : ``color`` or list of ``color``, optional
|
|
4672
4723
|
The colors of the bar faces. This is an alias for *facecolor*.
|
|
4673
4724
|
If both are given, *facecolor* takes precedence.
|
|
4674
4725
|
|
|
4675
|
-
facecolor :
|
|
4726
|
+
facecolor : ``color`` or list of ``color``, optional
|
|
4676
4727
|
The colors of the bar faces.
|
|
4677
4728
|
If both *color* and *facecolor are given, *facecolor* takes precedence.
|
|
4678
4729
|
|
|
4679
|
-
edgecolor :
|
|
4730
|
+
edgecolor : ``color`` or list of ``color``, optional
|
|
4680
4731
|
The colors of the bar edges.
|
|
4681
4732
|
|
|
4682
4733
|
linewidth : float or array-like, optional
|
|
@@ -4705,13 +4756,10 @@ class bar(plotObject):
|
|
|
4705
4756
|
errors.
|
|
4706
4757
|
- *None*: No errorbar. (Default)
|
|
4707
4758
|
|
|
4708
|
-
|
|
4709
|
-
the usage of *xerr* and *yerr*.
|
|
4710
|
-
|
|
4711
|
-
ecolor : :mpltype:`color` or list of :mpltype:`color`, default: 'black'
|
|
4759
|
+
ecolor : ``color`` or list of ``color``, default: 'black'
|
|
4712
4760
|
The line color of the errorbars.
|
|
4713
4761
|
|
|
4714
|
-
capsize : float, default:
|
|
4762
|
+
capsize : float, default: ``errorbar.capsize``
|
|
4715
4763
|
The length of the error bar caps in points.
|
|
4716
4764
|
|
|
4717
4765
|
error_kw : dict, optional
|
|
@@ -4736,7 +4784,7 @@ class bar(plotObject):
|
|
|
4736
4784
|
Notes
|
|
4737
4785
|
-----
|
|
4738
4786
|
Stacked bars can be achieved by passing individual *bottom* values per
|
|
4739
|
-
bar.
|
|
4787
|
+
bar.
|
|
4740
4788
|
"""
|
|
4741
4789
|
def __init__(self,x,height,width=0.8,bottom=0,easing=None,axis=None, *args, **kwargs):
|
|
4742
4790
|
#self.mpl_obj_type = mpl.container.BarContainer
|
|
@@ -4796,4 +4844,97 @@ class bar(plotObject):
|
|
|
4796
4844
|
kwargs['width'] = [0]
|
|
4797
4845
|
kwargs['bottom'] = [0]
|
|
4798
4846
|
obj = self.axis.bar(data_x,data_y,**kwargs)
|
|
4799
|
-
self.obj = obj
|
|
4847
|
+
self.obj = obj
|
|
4848
|
+
|
|
4849
|
+
class ConnectionPatch(plotObject):
|
|
4850
|
+
"""
|
|
4851
|
+
Connect point *xyA* in *coordsA* with point *xyB* in *coordsB*.
|
|
4852
|
+
|
|
4853
|
+
Parameters
|
|
4854
|
+
----------
|
|
4855
|
+
easing : callable, optional
|
|
4856
|
+
Easing function
|
|
4857
|
+
axis : matplotlib.axes.Axes, optional
|
|
4858
|
+
Axis to plot on
|
|
4859
|
+
|
|
4860
|
+
Valid keys are
|
|
4861
|
+
|
|
4862
|
+
=============== ======================================================
|
|
4863
|
+
Key Description
|
|
4864
|
+
=============== ======================================================
|
|
4865
|
+
arrowstyle the arrow style
|
|
4866
|
+
connectionstyle the connection style
|
|
4867
|
+
relpos default is (0.5, 0.5)
|
|
4868
|
+
patchA default is bounding box of the text
|
|
4869
|
+
patchB default is None
|
|
4870
|
+
shrinkA default is 2 points
|
|
4871
|
+
shrinkB default is 2 points
|
|
4872
|
+
mutation_scale default is text size (in points)
|
|
4873
|
+
mutation_aspect default is 1.
|
|
4874
|
+
? any key for `matplotlib.patches.PathPatch`
|
|
4875
|
+
=============== ======================================================
|
|
4876
|
+
|
|
4877
|
+
*coordsA* and *coordsB* are strings that indicate the
|
|
4878
|
+
coordinates of *xyA* and *xyB*.
|
|
4879
|
+
|
|
4880
|
+
==================== ==================================================
|
|
4881
|
+
Property Description
|
|
4882
|
+
==================== ==================================================
|
|
4883
|
+
'figure points' points from the lower left corner of the figure
|
|
4884
|
+
'figure pixels' pixels from the lower left corner of the figure
|
|
4885
|
+
'figure fraction' 0, 0 is lower left of figure and 1, 1 is upper
|
|
4886
|
+
right
|
|
4887
|
+
'subfigure points' points from the lower left corner of the subfigure
|
|
4888
|
+
'subfigure pixels' pixels from the lower left corner of the subfigure
|
|
4889
|
+
'subfigure fraction' fraction of the subfigure, 0, 0 is lower left.
|
|
4890
|
+
'axes points' points from lower left corner of the Axes
|
|
4891
|
+
'axes pixels' pixels from lower left corner of the Axes
|
|
4892
|
+
'axes fraction' 0, 0 is lower left of Axes and 1, 1 is upper right
|
|
4893
|
+
'data' use the coordinate system of the object being
|
|
4894
|
+
annotated (default)
|
|
4895
|
+
'offset points' offset (in points) from the *xy* value
|
|
4896
|
+
'polar' you can specify *theta*, *r* for the annotation,
|
|
4897
|
+
even in cartesian plots. Note that if you are
|
|
4898
|
+
using a polar Axes, you do not need to specify
|
|
4899
|
+
polar for the coordinate system since that is the
|
|
4900
|
+
native "data" coordinate system.
|
|
4901
|
+
==================== ==================================================
|
|
4902
|
+
|
|
4903
|
+
Alternatively they can be set to any valid
|
|
4904
|
+
`~matplotlib.transforms.Transform`.
|
|
4905
|
+
|
|
4906
|
+
Note that 'subfigure pixels' and 'figure pixels' are the same
|
|
4907
|
+
for the parent figure, so users who want code that is usable in
|
|
4908
|
+
a subfigure can use 'subfigure pixels'.
|
|
4909
|
+
|
|
4910
|
+
.. note::
|
|
4911
|
+
|
|
4912
|
+
Using `ConnectionPatch` across two `~.axes.Axes` instances
|
|
4913
|
+
is not directly compatible with :ref:`constrained layout
|
|
4914
|
+
<constrainedlayout_guide>`. Add the artist
|
|
4915
|
+
directly to the `.Figure` instead of adding it to a specific Axes,
|
|
4916
|
+
or exclude it from the layout using ``con.set_in_layout(False)``.
|
|
4917
|
+
|
|
4918
|
+
.. code-block:: default
|
|
4919
|
+
|
|
4920
|
+
fig, ax = plt.subplots(1, 2, constrained_layout=True)
|
|
4921
|
+
con = ConnectionPatch(..., axesA=ax[0], axesB=ax[1])
|
|
4922
|
+
fig.add_artist(con)
|
|
4923
|
+
|
|
4924
|
+
"""
|
|
4925
|
+
def __init__(self,xyA,xyB,coordsA,coordsB=None,easing=None,axis=None, *args, **kwargs):
|
|
4926
|
+
self.mpl_obj_type = mpl.patches.FancyArrowPatch
|
|
4927
|
+
kwargs['xyA'] = xyA
|
|
4928
|
+
kwargs['xyB'] = xyB
|
|
4929
|
+
kwargs['coordsA'] = coordsA
|
|
4930
|
+
kwargs['coordsB'] = coordsB
|
|
4931
|
+
super().__init__(easing=easing,axis=axis,*args, **kwargs)
|
|
4932
|
+
self.x = xyA[0]
|
|
4933
|
+
self.y = xyA[1]
|
|
4934
|
+
|
|
4935
|
+
def function(self,data_x,data_y,x,kwargs):
|
|
4936
|
+
if 'alpha' in kwargs and isinstance(kwargs['alpha'],np.ndarray):
|
|
4937
|
+
kwargs['alpha'] = kwargs['alpha'][0]
|
|
4938
|
+
|
|
4939
|
+
self.obj = mpl.patches.ConnectionPatch(**kwargs)
|
|
4940
|
+
self.axis.add_patch(self.obj)
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.6.3"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|