how to get the transpose of a matrix in numpy code example
Example 1: numpy transpose
>>> np.transpose(x)
array([[0, 2],
[1, 3]])
Example 2: transpose matrix python
arr = list(list(x) for x in zip(*arr))
>>> np.transpose(x)
array([[0, 2],
[1, 3]])
arr = list(list(x) for x in zip(*arr))