vector2xy#
- classmethod GnomonicProjection.vector2xy(v: Vector3d | ndarray) ndarray [source]#
[Deprecated] Convert from 3D cartesian coordinates \((x, y, z)\) to 2D Gnomonic coordinates \((x_g, y_g)\).
- Parameters:
- v
3D vector(s) on the form
[[x0, y0, z0], [x1, y1, z1], ...]
.
- Returns:
gnomonic_coordinates
Gnomonic coordinates on the form
[[x0, y0], [x1, y1], ...]
.
Notes
Deprecated since version 0.8.0: Function vector2xy() is deprecated and will be removed in version 0.9.0.
Examples
>>> import numpy as np >>> from kikuchipy.projections import GnomonicProjection >>> v = np.random.random_sample(30).reshape((10, 3)) >>> xy = GnomonicProjection.vector2xy(v)