method

vstack

Importance_1
Ruby latest stable (v2_5_5) - 0 notes - Class: Matrix
vstack(*matrices) public

Returns a new matrix resulting by stacking vertically the receiver with the given matrices

x = Matrix[[1, 2], [3, 4]]
y = Matrix[[5, 6], [7, 8]]
x.vstack(y) # => Matrix[[1, 2], [3, 4], [5, 6], [7, 8]]
Show source
Register or log in to add new notes.