# Metric - average count per bucket (one value for all buckets)

**URL:** <https://discuss.elastic.co/t/metric-average-count-per-bucket-one-value-for-all-buckets/37140>\
**Category:** Kibana\
**Created:** [December 14, 2015, 3:42pm UTC](https://discuss.elastic.co/t/metric-average-count-per-bucket-one-value-for-all-buckets/37140 "2015-12-14T15:42:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![hronecviktor](https://avatars.discourse-cdn.com/v4/letter/h/f19dbf/32.png) [@hronecviktor](https://discuss.elastic.co/u/hronecviktor)\
**Post date:** [December 14, 2015, 3:42pm UTC](https://discuss.elastic.co/t/metric-average-count-per-bucket-one-value-for-all-buckets/37140/1 "2015-12-14T15:42:41Z")

</div>

Hi everybody,

My elasticsearch index contains field called "sr\_id" - an ID of a user. Lots of records for each sr\_id.  
I need to create a "Metric" visualization to show how many records are related to a user on average. e.g.  
If there are:  
10 records with sr\_id: A  
5 records with sr\_id:B  
1 record with sr\_id:C

i need to display: Average records per user: 5

Please, does anybody have experience with metrics like these?  
Any help appreciated

---

<div class="post-metadata">

**Author:** ![BigFunger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/bigfunger/32/7323_2.png) [@BigFunger](https://discuss.elastic.co/u/BigFunger)\
**Post date:** [December 16, 2015, 5:22pm UTC](https://discuss.elastic.co/t/metric-average-count-per-bucket-one-value-for-all-buckets/37140/3 "2015-12-16T17:22:13Z")

</div>

hronecviktor,

Currently, there is no way to do that in Kibana. That requires pipeline aggregations, and it has been talked about a lot, but is probably not something that will be coming any time soon.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:06pm UTC](https://discuss.elastic.co/t/metric-average-count-per-bucket-one-value-for-all-buckets/37140/4 "2017-07-06T14:06:28Z")

</div>


