[Numpy-discussion] dot function or dot notation, matrices, arrays?
Fri Dec 18 16:51:25 CST 2009
That should do it. Thanks. How do I get the scalar result by itself?
Keith Goodman wrote:
> On Fri, Dec 18, 2009 at 1:51 PM, Wayne Watson
> <firstname.lastname@example.org> wrote:
>> Is it possible to calculate a dot product in numpy by either notation
>> (a ^ b, where ^ is a possible notation) or calling a dot function
>> (dot(a,b)? I'm trying to use a column matrix for both "vectors".
>> Perhaps, I need to somehow change them to arrays?
> Does this do what you want?
>>> x.T * x
> NumPy-Discussion mailing list
Wayne Watson (Watson Adventures, Prop., Nevada City, CA)
(121.015 Deg. W, 39.262 Deg. N) GMT-8 hr std. time)
Obz Site: 39° 15' 7" N, 121° 2' 32" W, 2700 feet
"... humans'innate skills with numbers isn't much
better than that of rats and dolphins."
-- Stanislas Dehaene, neurosurgeon
Web Page: <www.speckledwithstars.net/>
More information about the NumPy-Discussion