josdejong/mathjs — pull request #105 by guillermobox (2013-10-24 12:39:49+00:00)
Title: Fixed mean to use "size" instead of calculating it

Now using 'size', to calculate the mean of an n-dimensional array it's very easy:

```javascript
function _nmean(array, dim){
var sum;
sum = collection.reduce(array, dim, math.add);
return math.divide(sum, size(array)[dim]);
};
```