[Numpy-discussion] Rephrasing the question...
Magnus Lie Hetland
magnus at hetland.org
Tue Jun 25 14:01:03 EDT 2002
Thanks for the input on k-means clustering, but the main questionw as
actully this... If I have the following:
for i in xrange(k):
w[i] = average(compress(C == i, V, 0))
... can that be expressed without the Python for loop? (I.e. without
using compress etc.) I want w[i] to be the average of the vectors in
V[x] for which C[x] == i...
Magnus Lie Hetland The Anygui Project
More information about the NumPy-Discussion