How to multiply two vector and get a matrix?
Normal matrix multiplication works as long as the vectors have the right shape. Remember that * in Numpy is elementwise multiplication, and matrix multiplication is available with numpy.dot() (or with the @ operator, in Python 3.5) >>> numpy.dot(numpy.array([[1], [2]]), numpy.array([[3, 4]])) array([[3, 4], [6, 8]]) This is called an “outer product.” You can get it … Read more