# Advanced JSON input of Parent Pipeline Aggregation of Metric Aggregation

**URL:** <https://discuss.elastic.co/t/advanced-json-input-of-parent-pipeline-aggregation-of-metric-aggregation/179080>\
**Category:** Kibana\
**Created:** [April 30, 2019, 12:07pm UTC](https://discuss.elastic.co/t/advanced-json-input-of-parent-pipeline-aggregation-of-metric-aggregation/179080 "2019-04-30T12:07:59Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![6tUBp3gwd9Zp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/6tubp3gwd9zp/32/45240_2.png) [@6tUBp3gwd9Zp](https://discuss.elastic.co/u/6tUBp3gwd9Zp)\
**Post date:** [April 30, 2019, 12:07pm UTC](https://discuss.elastic.co/t/advanced-json-input-of-parent-pipeline-aggregation-of-metric-aggregation/179080/1 "2019-04-30T12:07:59Z")

</div>

When making a normal metric aggregation i can modify the values before plotting them in a line chart via the advanced JSON input like this for example:

```
{"script": {
"inline": "Math.abs(_value)",
"lang": "painless"}}

```

But when i want to modify the value of a serial diff of a metric aggregation it doesnt work. Is it somehow possible?

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/3/1/31351bbc749aa667e4167766928ebfd6c17a7bed.png)

---

<div class="post-metadata">

**Author:** ![pchakour](https://avatars.discourse-cdn.com/v4/letter/p/e36b37/32.png) [@pchakour](https://discuss.elastic.co/u/pchakour)\
**Post date:** [May 2, 2019, 3:26pm UTC](https://discuss.elastic.co/t/advanced-json-input-of-parent-pipeline-aggregation-of-metric-aggregation/179080/2 "2019-05-02T15:26:07Z")

</div>

Try this plugin I think it could help you : [https://github.com/datasweet/kibana-datasweet-formula](https://github.com/datasweet/kibana-datasweet-formula)

---

<div class="post-metadata">

**Author:** ![6tUBp3gwd9Zp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/6tubp3gwd9zp/32/45240_2.png) [@6tUBp3gwd9Zp](https://discuss.elastic.co/u/6tUBp3gwd9Zp)\
**Post date:** [May 3, 2019, 9:03am UTC](https://discuss.elastic.co/t/advanced-json-input-of-parent-pipeline-aggregation-of-metric-aggregation/179080/3 "2019-05-03T09:03:37Z")

</div>

Thank you very much this looks exactly like what i need. I will check this 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:** [May 31, 2019, 9:03am UTC](https://discuss.elastic.co/t/advanced-json-input-of-parent-pipeline-aggregation-of-metric-aggregation/179080/4 "2019-05-31T09:03:45Z")

</div>

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