Computes the nD bounds of given vectors. vmin should be initialized to +∞ and vmax to -∞ (e.g. use copies of MIN* / MAX* constants defined in thi.ng/vectors).
vmin
+∞
vmax
-∞
MIN*
MAX*
points = [[-1,-2], [5,-3], [0,4]]; bounds(points, [...MAX2], [...MIN2]) // [[-1,-3],[5,4]]
Returns 2-tuple of modified [vmin, vmax].
[vmin, vmax]
point
min result (pre-initialized to +∞)
max result (pre-initialized to -∞)
Generated using TypeDoc
Computes the nD bounds of given vectors.
vmin
should be initialized to+∞
andvmax
to-∞
(e.g. use copies ofMIN*
/MAX*
constants defined in thi.ng/vectors).points = [[-1,-2], [5,-3], [0,4]]; bounds(points, [...MAX2], [...MIN2]) // [[-1,-3],[5,4]]
Returns 2-tuple of modified
[vmin, vmax]
.