Defining a vector
At the time of defining a vector through following formula, a row vector is defined.
v = np.array([1,2,3])
means vector v(1*3) dimension
But why v.shape function return (3,). it seams that shape function treated row vector as column vector.
1 answers ( 0 marked as helpful)
Hi Muhammad,
When we are talking about a vector, in terms of shape, there is no difference between a row vector and a column vector.
I know it is a bit confusing, however, this is how Python handles vectors.
Best,
The 365 Team
The 365 Team