# Export forecast data

**URL:** https://discuss.elastic.co/t/export-forecast-data/124875
**Category:** Elasticsearch
**Tags:** elastic-stack-machine-learning
**Created:** [March 20, 2018, 11:16pm UTC](https://discuss.elastic.co/t/export-forecast-data/124875 "2018-03-20T23:16:42Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![Hendrik\_Muhs](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/hendrik_muhs/32/25802_2.png) [@Hendrik\_Muhs](https://discuss.elastic.co/u/Hendrik_Muhs)
#### Post date: [March 21, 2018, 8:12am UTC](https://discuss.elastic.co/t/export-forecast-data/124875/2 "2018-03-21T08:12:09Z")

</div>

Hi Oscar,

all forecast results are written back to the result index of the job, that is default the shared index: `.ml-anomalies-shared` but you can also use a dedicated index.

Therefore you can access all results via search, e.g.

```
GET .ml-anomalies-shared/_search
{
  "query": {
    "bool": {
      "filter": [
        {
          "query_string": {
            "query": "result_type:model_forecast"
          }
        },
        {
          "query_string": {
            "query": "job_id:n1"
          }
        }
      ]
    }
  }
}

```

In the result you will see the fields `forecast_lower`, `forecast_upper`, `forecast_prediction` along with `timestamp` which is the timestamp of the prediction.

Happy forecasting!

---

_[View the full topic](https://discuss.elastic.co/t/export-forecast-data/124875)._
