# Holidays Data for Forecast

In this page, I will introduce how to set holidays data for time series forecasting.

## Import Holiday Data

We provide a data extension to get bank holidays, so let's import data from it.

It can be used from this "Import Extension Data" dropdown menu.

![](https://2850417076-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M4HLCK3olgduYoe3RVS%2F-M4oMvCUDQwHTJ0eWi_f%2F-M4oNFgo_5xMywP830y9%2Fextension_data.png?generation=1586795489798079\&alt=media)

If you haven't installed the extension yet, please add it from "Add New" button. Then, the plugin is added to "Installed" and you can import data from "Import Data".

![](https://2850417076-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M4HLCK3olgduYoe3RVS%2F-M4oMvCUDQwHTJ0eWi_f%2F-M4oNFgqp6BiC3YRDHAM%2Fholiday_extension.png?generation=1586795489699378\&alt=media)

You can choose holiday type, start year and end year.

![](https://2850417076-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M4HLCK3olgduYoe3RVS%2F-M4oMvCUDQwHTJ0eWi_f%2F-M4oNFgtmRVtRocwhK8C%2Fholiday_dialog.png?generation=1586795490482018\&alt=media)

If you import the data, it will be like this.

![](https://2850417076-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M4HLCK3olgduYoe3RVS%2F-M4oMvCUDQwHTJ0eWi_f%2F-M4oNFgxH_407wPMOJ46%2Fholiday_data.png?generation=1586795489858399\&alt=media)

## Set Up Data Format

do\_prophet, which is the function for time series forecast, expect the name of the date column to be "ds", so let's rename it.

![](https://2850417076-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M4HLCK3olgduYoe3RVS%2F-M4oMvCUDQwHTJ0eWi_f%2F-M4oNFh1svHdhM8HNi9B%2Fholiday_rename.png?generation=1586795489965708\&alt=media)

And it also need "holiday" column, so let's create it.

![](https://2850417076-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M4HLCK3olgduYoe3RVS%2F-M4oMvCUDQwHTJ0eWi_f%2F-M4oNFh39P1IB5omto4X%2Fholiday_column.png?generation=1586795489922875\&alt=media)

If you'd like to to have the effect of holiday before or after the holiday too, you can also add "lower\_window" column and "upper\_window" column. For example, if you want the holiday effect to take effect from 1 day before the holiday to 1 day after the holiday, you can set -1 to the "lower\_window" column, and 1 to the "upper\_window" column. For more detail on the content of the data frame for holidays, refer to [the official document of Prophet](https://facebook.github.io/prophet/docs/seasonality,_holiday_effects,_and_regressors.html).

## Use it from Time Series Forecast

Then, you can choose this data frame from Time Series Forecast dialog and the dates in the data frame are recognized as holidays.

![](https://2850417076-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M4HLCK3olgduYoe3RVS%2F-M4oMvCUDQwHTJ0eWi_f%2F-M4oNFh5Zp9UJ_2ClkSW%2Fholiday_command.png?generation=1586795490107849\&alt=media)
