# Call R script from elastic aggregation

**URL:** <https://discuss.elastic.co/t/call-r-script-from-elastic-aggregation/74525>\
**Category:** Elasticsearch\
**Created:** [February 9, 2017, 3:58pm UTC](https://discuss.elastic.co/t/call-r-script-from-elastic-aggregation/74525 "2017-02-09T15:58:56Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![liorg2](https://avatars.discourse-cdn.com/v4/letter/l/ed8c4c/32.png) [@liorg2](https://discuss.elastic.co/u/liorg2)\
**Post date:** [February 9, 2017, 3:58pm UTC](https://discuss.elastic.co/t/call-r-script-from-elastic-aggregation/74525/1 "2017-02-09T15:58:56Z")

</div>

Is it possible to call R script from aggregation? Same as the built in moving avarage, but using my own script?

Thanks

---

<div class="post-metadata">

**Author:** ![nik9000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nik9000/32/44947_2.png) [@nik9000](https://discuss.elastic.co/u/nik9000)\
**Post date:** [February 9, 2017, 9:31pm UTC](https://discuss.elastic.co/t/call-r-script-from-elastic-aggregation/74525/2 "2017-02-09T21:31:54Z")

</div>

No. There are R clients that let you call Elasticsearch from R, but not the  
other way around.

---

<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:** [March 9, 2017, 9:32pm UTC](https://discuss.elastic.co/t/call-r-script-from-elastic-aggregation/74525/3 "2017-03-09T21:32:20Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
