Take a look at pipeline aggregations. These are aggregations that work on the result of other aggregations. In your example, you could use a bucket_script pipeline aggregation:
This does not work for root-level aggregations. So, the sum_1, sum_2 and division aggregations must be child aggregations inside a multi-bucket aggregation.
All of that should be possible, with the exception of the data table. I don't think Timelion supports data tables.
Take a look at the built-in tutorial to see what it can do. Timelion's syntax is very different from the regular aggregations, so there is a bit of a learning curve.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.