python vstack numpy code example
Example 1: np vstack
>>> a = np.array([1, 2, 3])
>>> b = np.array([2, 3, 4])
>>> np.vstack((a,b))
array([[1, 2, 3],
[2, 3, 4]])
>>> a = np.array([[1], [2], [3]])
>>> b = np.array([[2], [3], [4]])
>>> np.vstack((a,b))
array([[1],
[2],
[3],
[2],
[3],
[4]])
Example 2: np.vstack python
import numpy as np
a = np.array([1, 2, 3])
b = np.array([2, 3, 4])
np.vstack((a,b))