# \[Ann\]: Distinct Term Facet alpha (hyperloglog estimation)

**URL:** <https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935>\
**Category:** Elasticsearch\
**Created:** [December 4, 2012, 5:05pm UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935 "2012-12-04T17:05:12Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Valentin\_Pletzer](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/valentin_pletzer/32/105548_2.png) [@Valentin\_Pletzer](https://discuss.elastic.co/u/Valentin_Pletzer)\
**Post date:** [December 4, 2012, 5:05pm UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935/1 "2012-12-04T17:05:12Z")

</div>

Thanks to Igor Motov I just finished my first elasticsearch code (for the  
facet script plugin). Its still an early prototype but I thought I should  
release and share early.

It works similar to the  
approx-plugin [https://github.com/ptdavteam/elasticsearch-approx-plugin](https://github.com/ptdavteam/elasticsearch-approx-plugin)  
which gives you a distinct elements histogram. An approximation of unique  
elements within a time slot.

My plugin does something similar but is similar to the original term facet.  
It gives you an estimate of the distinct elements for one field, based on  
another.

Mind to share your thoughts? Any feedback is welcome. And I am more than  
happy to discuss it.

--

---

<div class="post-metadata">

**Author:** ![Igor\_Motov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igor_motov/32/45193_2.png) [@Igor\_Motov](https://discuss.elastic.co/u/Igor_Motov)\
**Post date:** [December 6, 2012, 10:28pm UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935/2 "2012-12-06T22:28:25Z")

</div>

Is source for your plugin available somewhere?

On Tuesday, December 4, 2012 12:05:12 PM UTC-5, Valentin wrote:

> Thanks to Igor Motov I just finished my first elasticsearch code (for the  
> facet script plugin). Its still an early prototype but I thought I should  
> release and share early.
> 
> It works similar to the approx-plugin  
> [GitHub - pearson-enabling-technologies/elasticsearch-approx-plugin: Plugin for ElasticSearch to do approximate or exact distinct counts, and fast term lists](https://github.com/ptdavteam/elasticsearch-approx-plugin) which gives you  
> a distinct elements histogram. An approximation of unique elements within a  
> time slot.
> 
> My plugin does something similar but is similar to the original term  
> facet. It gives you an estimate of the distinct elements for one field,  
> based on another.
> 
> Mind to share your thoughts? Any feedback is welcome. And I am more than  
> happy to discuss it.

--

---

<div class="post-metadata">

**Author:** ![dobe](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dobe/32/2152_2.png) [@dobe](https://discuss.elastic.co/u/dobe)\
**Post date:** [December 7, 2012, 6:27am UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935/3 "2012-12-07T06:27:55Z")

</div>

maybe this is also of interest for you, there is a distinct date histogram  
facet

> **[GitHub - crate/elasticsearch-timefacets-plugin: Elasticsearch Timebased Facets](https://github.com/crate/elasticsearch-timefacets-plugin)**
>
> Elasticsearch Timebased Facets. Contribute to crate/elasticsearch-timefacets-plugin development by creating an account on GitHub.

On Tuesday, December 4, 2012 6:05:12 PM UTC+1, Valentin wrote:

> Thanks to Igor Motov I just finished my first elasticsearch code (for the  
> facet script plugin). Its still an early prototype but I thought I should  
> release and share early.
> 
> It works similar to the approx-plugin  
> [GitHub - pearson-enabling-technologies/elasticsearch-approx-plugin: Plugin for ElasticSearch to do approximate or exact distinct counts, and fast term lists](https://github.com/ptdavteam/elasticsearch-approx-plugin) which gives you  
> a distinct elements histogram. An approximation of unique elements within a  
> time slot.
> 
> My plugin does something similar but is similar to the original term  
> facet. It gives you an estimate of the distinct elements for one field,  
> based on another.
> 
> Mind to share your thoughts? Any feedback is welcome. And I am more than  
> happy to discuss it.

--

---

<div class="post-metadata">

**Author:** ![Valentin\_Pletzer](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/valentin_pletzer/32/105548_2.png) [@Valentin\_Pletzer](https://discuss.elastic.co/u/Valentin_Pletzer)\
**Post date:** [December 9, 2012, 6:39pm UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935/4 "2012-12-09T18:39:44Z")

</div>

I can't believe I forgot the link: [hyperloglog for elasticsearch script facet plugin (alpha code) · GitHub](https://gist.github.com/4206141)

Shame on me.

On Thursday, December 6, 2012 11:28:25 PM UTC+1, Igor Motov wrote:

> Is source for your plugin available somewhere?
> 
> On Tuesday, December 4, 2012 12:05:12 PM UTC-5, Valentin wrote:
> 
> > Thanks to Igor Motov I just finished my first elasticsearch code (for the  
> > facet script plugin). Its still an early prototype but I thought I should  
> > release and share early.
> > 
> > It works similar to the approx-plugin  
> > [GitHub - pearson-enabling-technologies/elasticsearch-approx-plugin: Plugin for ElasticSearch to do approximate or exact distinct counts, and fast term lists](https://github.com/ptdavteam/elasticsearch-approx-plugin) which gives you  
> > a distinct elements histogram. An approximation of unique elements within a  
> > time slot.
> > 
> > My plugin does something similar but is similar to the original term  
> > facet. It gives you an estimate of the distinct elements for one field,  
> > based on another.
> > 
> > Mind to share your thoughts? Any feedback is welcome. And I am more than  
> > happy to discuss it.

--

---

<div class="post-metadata">

**Author:** ![Jerome\_Gagnon](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jerome_gagnon/32/2178_2.png) [@Jerome\_Gagnon](https://discuss.elastic.co/u/Jerome_Gagnon)\
**Post date:** [December 11, 2012, 4:41pm UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935/5 "2012-12-11T16:41:05Z")

</div>

Nice, can't wait to try it !!

On Sunday, December 9, 2012 1:39:44 PM UTC-5, Valentin wrote:

> I can't believe I forgot the link: [hyperloglog for elasticsearch script facet plugin (alpha code) · GitHub](https://gist.github.com/4206141)
> 
> Shame on me.
> 
> On Thursday, December 6, 2012 11:28:25 PM UTC+1, Igor Motov wrote:
> 
> > Is source for your plugin available somewhere?
> > 
> > On Tuesday, December 4, 2012 12:05:12 PM UTC-5, Valentin wrote:
> > 
> > > Thanks to Igor Motov I just finished my first elasticsearch code (for  
> > > the facet script plugin). Its still an early prototype but I thought I  
> > > should release and share early.
> > > 
> > > It works similar to the approx-plugin  
> > > [GitHub - pearson-enabling-technologies/elasticsearch-approx-plugin: Plugin for ElasticSearch to do approximate or exact distinct counts, and fast term lists](https://github.com/ptdavteam/elasticsearch-approx-plugin) which gives  
> > > you a distinct elements histogram. An approximation of unique elements  
> > > within a time slot.
> > > 
> > > My plugin does something similar but is similar to the original term  
> > > facet. It gives you an estimate of the distinct elements for one field,  
> > > based on another.
> > > 
> > > Mind to share your thoughts? Any feedback is welcome. And I am more than  
> > > happy to discuss it.

--

---

<div class="post-metadata">

**Author:** ![kajal](https://avatars.discourse-cdn.com/v4/letter/k/7993a0/32.png) [@kajal](https://discuss.elastic.co/u/kajal)\
**Post date:** [July 31, 2013, 9:37pm UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935/6 "2013-07-31T21:37:40Z")

</div>

Does anyone has code sample for es Java api. I mean usage of this using  
Elastic search java API? It works fine using rest API but I am having  
trouble running it in ES JAVA API.

On Sunday, December 9, 2012 1:39:44 PM UTC-5, Valentin wrote:

> I can't believe I forgot the link: [hyperloglog for elasticsearch script facet plugin (alpha code) · GitHub](https://gist.github.com/4206141)
> 
> Shame on me.
> 
> On Thursday, December 6, 2012 11:28:25 PM UTC+1, Igor Motov wrote:
> 
> > Is source for your plugin available somewhere?
> > 
> > On Tuesday, December 4, 2012 12:05:12 PM UTC-5, Valentin wrote:
> > 
> > > Thanks to Igor Motov I just finished my first elasticsearch code (for  
> > > the facet script plugin). Its still an early prototype but I thought I  
> > > should release and share early.
> > > 
> > > It works similar to the approx-plugin  
> > > [GitHub - pearson-enabling-technologies/elasticsearch-approx-plugin: Plugin for ElasticSearch to do approximate or exact distinct counts, and fast term lists](https://github.com/ptdavteam/elasticsearch-approx-plugin) which gives  
> > > you a distinct elements histogram. An approximation of unique elements  
> > > within a time slot.
> > > 
> > > My plugin does something similar but is similar to the original term  
> > > facet. It gives you an estimate of the distinct elements for one field,  
> > > based on another.
> > > 
> > > Mind to share your thoughts? Any feedback is welcome. And I am more than  
> > > happy to discuss it.

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<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:23am UTC](https://discuss.elastic.co/t/ann-distinct-term-facet-alpha-hyperloglog-estimation/9935/7 "2017-07-06T02:23:28Z")

</div>


