# Forecasting (Beta)

<figure><img src="https://2516160394-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmAOqTQkYofJrevcpklA7%2Fuploads%2FiRZi8LOG8hu4eUV4HXmD%2FScreenshot%202024-03-21%20at%2015.14.00.png?alt=media&#x26;token=3d5fed3e-10f4-444c-a9a8-015214261210" alt=""><figcaption><p>Automated Forecasting</p></figcaption></figure>

Thanks to its analytical capabilities, Crystal can explain what happened to your data in the **past** and in the **present** (see [Automated Insights](https://docs.igenius.ai/crystal-advisor/analyze-your-data/automated-insights) / [Insights Analysis](https://docs.igenius.ai/crystal-advisor/analyze-your-data/insight-analysis) and [Alerts](https://docs.igenius.ai/crystal-advisor/analyze-your-data/alerts) respectively).

But what about the **future**?&#x20;

With the **Automated Forecasting** capability, Crystal can also foresee how your Topics evolve in time,  enabling you to make better decisions by **anticipating time**!

{% hint style="success" %} <mark style="color:green;">**Pills of Data Analysis**</mark>

Automated Forecasting is a Data Analysis technique that is part of the **Predictive Analytics** branch and **uses Machine Learning to** **predict** **how trends might evolve in the future** based on **historical data**.&#x20;

This kind of analysis can only be applied to Topics that track a single Entity progress in time, i.e. the **Single Line Overtime** ones.
{% endhint %}

{% hint style="warning" %} <mark style="color:orange;">**Remember**</mark>

This feature is still in Beta.
{% endhint %}

## Request a Forecast

You can request a Forecast by setting it up from a Topic Card.

### Set up from Topic Card

You can request a Forecast from the Topic Card, like this:

1. Ask for the Topic you want to monitor.
2. Once the requested Topic is returned on the Advisor, navigate through the Topic Card, click on the three-dot menu, and select the *"Forecast"* icon.

<figure><img src="https://2516160394-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmAOqTQkYofJrevcpklA7%2Fuploads%2F3QyByTwvtRf03HnambHY%2FScreenshot%202024-03-21%20at%2016.28.39.png?alt=media&#x26;token=76668a18-b6be-475e-b5dc-b45cf78f620e" alt=""><figcaption><p>Set a Forecast</p></figcaption></figure>

## Check the Activation Status

At this point, Crystal will give you a feedback about the result of your request.

<details>

<summary>Feedback about the Request</summary>

These are the possible scenarios:

* Forecast set correctly
* Forecast already active
* Technical errors (not enough data, not applicable, no network, etc...)

</details>

Once the Forecast has been requested, you simply need to wait until the analysis is available.

## Receive a Forecast Notification

When the forecast is available, you'll receive a notification in the Notification Center.

This is what happens in this case:

1. When the notification arrives, open the Notification Center and read it. This notification signals that the forecast is ready.

<figure><img src="https://2516160394-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmAOqTQkYofJrevcpklA7%2Fuploads%2FTib8AgyFRHr8DvGXfWds%2FScreenshot%202024-03-21%20at%2016.37.16.png?alt=media&#x26;token=6d448476-3dcc-44da-b4da-089518354fca" alt="" width="284"><figcaption><p>Forecast Ready</p></figcaption></figure>

3. To know more, simply tap on the notification to be redirected to the Advisor
4. You will then see the Topic of interest with an intro message that tells you that your *Topic Forecast is ready.* Take a look and see how it will change in the future!

Notice that the results of your Forecast include three different lines: **"Forecast"**, **"Upper Bound"**, and **"Lower Bound"**. The actual Forecast is represented by the central line ("Forecast"), while the other lines ("Upper bound" and "Lower bound") serve as *confidence intervals*: i.e. the elements that define the range within which the actual forecast is confidently expected to lie.

<figure><img src="https://2516160394-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmAOqTQkYofJrevcpklA7%2Fuploads%2F3VUIwwj9GqzIz23Ry12M%2FScreenshot%202024-03-21%20at%2016.39.00.png?alt=media&#x26;token=26961fa7-3835-4c0b-a5ca-60f31daaab44" alt=""><figcaption><p>Topic Forecast</p></figcaption></figure>

With the Forecast feature, you can now make better decisions by **anticipating time**!

{% hint style="warning" %} <mark style="color:orange;">**Remember**</mark>

As of now, the actions of the Topic Card are not available for Topics containing a Forecast.

For example, you cannot save it to Data Stories, share it, etc.

In particular, not sharing this kind of Topic allows for enhanced data privacy.
{% endhint %}

## How Does It Work?

This is how Crystal can make predictions.

Once a Forecast is requested, Crystal immediately starts to collect the **historical data** behind that Topic to make **statistical calculations** and estimate how it might evolve.

This is why the final result includes both the **actual forecast** and the **confidence intervals**, which define the range within which the actual forecast is confidently expected to lie.

#### Rules

* This feature is only available for **Single-Line Overtime** Topics
* In order to guarantee the maximum accuracy and reliability of the resulting predictions, each Topic must meet the **conditions of minimal data point presence**

<details>

<summary>Conditions</summary>

For each time aggregation supported by the Single-Line Overtime, the data points must be:

* **Daily**: >35&#x20;
* **Weekly**: >9&#x20;
* **Monthly**: >18&#x20;
* **Quarterly**: >9&#x20;
* **Semesterly**: >7&#x20;
* **Yearly**: >6&#x20;

</details>

* The **horizon** of the predictable future data points is **dynamic** and algorithmically declared based on the number of data points available.
* In order to make up for potential data incompleteness, especially in monthly or daily Topics, the statistical model omits the initial and final data points when the metric aggregation function is set to **add up** or **count** (including the points in the analysis, particularly when there's only partial data for the last month, which could lead to misleading predictions).
* If there are **Dynamic Filters** applied to the Topic, the Forecast generated will take them into account.

#### Limitations

* This feature is still in **Beta Version**

Keep analyzing your data!

***
