On 9/11/2014 6:34 AM, Radhika Gaonkar wrote:
I have an implementation of lsa, that I need to modify. I am having some
trouble understanding the code. This is the line where I am stuck:

DocsPerWord = sum(asarray(self.A > 0, 'i'), axis=1)

Python doesn't provide an axis parameter for the sum builtin -- this sum function comes from numpy. See http://docs.scipy.org/doc/numpy/reference/generated/numpy.sum.html for details.

Emile

_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to