Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fix bm avg

  • Loading branch information...
commit 8b4fb27bb96b00db70dc2b7d5414d872002f330f 1 parent a543b79
@tj authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 benchmark/sub.js
View
4 benchmark/sub.js
@@ -55,10 +55,10 @@ function median(arr) {
process.on('SIGINT', function(){
var ms = Date.now() - start;
- var avg = mean(results);
+ var avg = n / (ms / 1000);
console.log('\n');
console.log(' min: %s ops/s', humanize(min(results)));
- console.log(' mean: %s ops/s', humanize(avg));
+ console.log(' mean: %s ops/s', humanize(avg | 0));
console.log(' median: %s ops/s', humanize(median(results)));
console.log(' total: %s ops in %ds', humanize(n), ms / 1000);
console.log(' through: %d mb/s', ((avg * bytes) / 1024 / 1024).toFixed(2));
Please sign in to comment.
Something went wrong with that request. Please try again.