MCPcopy Index your code
hub / github.com/plotly/plotly.py / traj

Method traj

plotly/figure_factory/_streamline.py:276–291  ·  view source on GitHub ↗

Integrate trajectories :param (int) xb: results of passing xi through self.blank_pos :param (int) xy: results of passing yi through self.blank_pos Calculate each trajectory based on rk4 integrate method.

(self, xb, yb)

Source from the content-addressed store, hash-verified

274 return None
275
276 def traj(self, xb, yb):
277 """
278 Integrate trajectories
279
280 :param (int) xb: results of passing xi through self.blank_pos
281 :param (int) xy: results of passing yi through self.blank_pos
282
283 Calculate each trajectory based on rk4 integrate method.
284 """
285
286 if xb < 0 or xb >= self.density or yb < 0 or yb >= self.density:
287 return
288 if self.blank[yb, xb] == 0:
289 t = self.rk4_integrate(xb * self.spacing_x, yb * self.spacing_y)
290 if t is not None:
291 self.trajectories.append(t)
292
293 def get_streamlines(self):
294 """

Callers 1

get_streamlinesMethod · 0.95

Calls 1

rk4_integrateMethod · 0.95

Tested by

no test coverage detected