feat(elasticsearch): began work on supporting extended stats metric agg, it gives you standard deviation and more

This commit is contained in:
Torkel Ödegaard
2015-09-05 20:22:54 +02:00
parent 52eeefa6d9
commit b24c539206
3 changed files with 24 additions and 7 deletions

View File

@@ -213,6 +213,15 @@ function (angular, _, config, kbn, moment, ElasticQueryBuilder) {
}
break;
}
case 'extended_stats': {
var stats = bucket[metric.id];
for (var statIndex in metric.stats) {
var statName = metric.stats[statIndex];
addMetricPoint(seriesName + ' ' + statName, stats[statName], bucket.key)
}
break;
}
default: {
seriesName += ' ' + metric.field + ' ' + metric.type;
value = bucket[metric.id].value;