accumarray()\'sval argument must be a vector. In my case I need columns of a matrix to be summed (or averaged). Is there a function or a method to achieve this?