diff --git a/ui/javascripts/app/helpers.js b/ui/javascripts/app/helpers.js
index c555088169..69b5e1ea3f 100644
--- a/ui/javascripts/app/helpers.js
+++ b/ui/javascripts/app/helpers.js
@@ -104,7 +104,6 @@ Ember.Handlebars.helper('tomographyGraph', function(tomography, size) {
// if/when Handlebars fixes the underlying issues all of this can be cleaned
// up drastically.
- var n = tomography.n;
var max = Math.max.apply(null, tomography.distances);
var insetSize = size / 2 - 8;
var buf = '' +
@@ -118,7 +117,12 @@ Ember.Handlebars.helper('tomographyGraph', function(tomography, size) {
' ' +
' ' +
' ';
- tomography.distances.forEach(function (distance, i) {
+ var sampling = 360 / tomography.n;
+ distances = tomography.distances.filter(function () {
+ return Math.random() < sampling
+ });
+ var n = distances.length;
+ distances.forEach(function (distance, i) {
buf += ' ';
});
buf += '' +