{"action":"created","issue":{"url":"https://api.github.com/repos/ml31415/accumarray/issues/1","labels_url":"https://api.github.com/repos/ml31415/accumarray/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/ml31415/accumarray/issues/1/comments","events_url":"https://api.github.com/repos/ml31415/accumarray/issues/1/events","html_url":"https://github.com/ml31415/accumarray/issues/1","id":48207369,"number":1,"title":"what about numpy's ufunc.at and bincounts?","user":{"login":"d1manson","id":4244876,"avatar_url":"https://avatars.githubusercontent.com/u/4244876?v=3","gravatar_id":"","url":"https://api.github.com/users/d1manson","html_url":"https://github.com/d1manson","followers_url":"https://api.github.com/users/d1manson/followers","following_url":"https://api.github.com/users/d1manson/following{/other_user}","gists_url":"https://api.github.com/users/d1manson/gists{/gist_id}","starred_url":"https://api.github.com/users/d1manson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/d1manson/subscriptions","organizations_url":"https://api.github.com/users/d1manson/orgs","repos_url":"https://api.github.com/users/d1manson/repos","events_url":"https://api.github.com/users/d1manson/events{/privacy}","received_events_url":"https://api.github.com/users/d1manson/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":18,"created_at":"2014-11-09T17:29:28Z","updated_at":"2015-05-27T21:14:41Z","closed_at":null,"body":"The syntax for [np.ufunc.at](http://docs.scipy.org/doc/numpy/reference/generated/numpy.ufunc.at.html#numpy.ufunc.at) is a bit different to Matlab's accumarry but I think it's basically doing the same thing.\r\n\r\nAlso, for the case of \"add\" you can use [np.bincount](http://docs.scipy.org/doc/numpy/reference/generated/numpy.bincount.html) as it has a weights arg.\r\n\r\nI've made [my own version of accumarray](https://gist.github.com/d1manson/5f78561c0f52d3073fe8) that encapsulates these two features in one Matlab-like interface.  It also optimizes for a couple of other functions \"first\" and \"last\", which simply make use of the repeated indexing rules."},"comment":{"url":"https://api.github.com/repos/ml31415/accumarray/issues/comments/106080634","html_url":"https://github.com/ml31415/accumarray/issues/1#issuecomment-106080634","issue_url":"https://api.github.com/repos/ml31415/accumarray/issues/1","id":106080634,"user":{"login":"ml31415","id":2386612,"avatar_url":"https://avatars.githubusercontent.com/u/2386612?v=3","gravatar_id":"","url":"https://api.github.com/users/ml31415","html_url":"https://github.com/ml31415","followers_url":"https://api.github.com/users/ml31415/followers","following_url":"https://api.github.com/users/ml31415/following{/other_user}","gists_url":"https://api.github.com/users/ml31415/gists{/gist_id}","starred_url":"https://api.github.com/users/ml31415/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ml31415/subscriptions","organizations_url":"https://api.github.com/users/ml31415/orgs","repos_url":"https://api.github.com/users/ml31415/repos","events_url":"https://api.github.com/users/ml31415/events{/privacy}","received_events_url":"https://api.github.com/users/ml31415/received_events","type":"User","site_admin":false},"created_at":"2015-05-27T21:14:41Z","updated_at":"2015-05-27T21:14:41Z","body":"Indeed, simple indexing ... just with _fill_untouched. Sometimes it needs a kick in the ass to see the simple solutions right in front of your eyes. Thanks for the hint!"}}