---
type: concept
x-llmwiki:
  schemaVersion: "0.1"
  contentHash: f1eb5b3b80880a7bb36d50beff09efbe92792c82e230c968e256934d92fd9392
  pageDirectory: concepts
  sources:
    - data-preparation-for-forecasting-databricks-on-aws.md
  confidence: 1
  provenanceState: extracted
  freshnessStatus: unverified
  aliases:
    - automl-forecasting-data-preparation
    - AFDP
    - Forecasting Data Preparation
  citations:
    - file: data-preparation-for-forecasting-databricks-on-aws.md
title: AutoML Forecasting Data Preparation
description: How Databricks AutoML prepares data for forecasting training, including supported feature types, imputation, splitting, and aggregation.
tags:
  - machine-learning
  - forecasting
  - databricks
timestamp: "2026-06-18T14:59:45.992Z"
---

# AutoML Forecasting Data Preparation

**AutoML Forecasting Data Preparation** describes how AutoML prepares [time series data](/concepts/time-series-feature-tables.md) for [forecasting](/concepts/forecast.md) training, including the supported feature types, missing value imputation, data splitting, and time series aggregation. These settings can be configured during experiment setup in the AutoML UI or through the AutoML API. ^[data-preparation-for-forecasting-databricks-on-aws.md]

## Supported Data Feature Types

AutoML forecasting supports only specific feature types for time series data. The following feature types are supported:

- **Numeric**: `ByteType`, `ShortType`, `IntegerType`, `LongType`, `FloatType`, and `DoubleType`
- **Boolean**
- **String**: categorical or English text
- **Timestamps**: `TimestampType`, `DateType`
- **ArrayType[Numeric]**: Databricks Runtime 10.4 LTS ML and above
- **DecimalType**: Databricks Runtime 11.3 LTS ML and above

Image data is not supported for forecasting. ^[data-preparation-for-forecasting-databricks-on-aws.md]

## Impute Missing Values

In Databricks Runtime 10.4 LTS ML and above, you can specify how null values are imputed for forecasting. In the UI, select a method from the drop-down in the **Impute with** column in the table schema. In the API, use the `imputers` parameter. ^[data-preparation-for-forecasting-databricks-on-aws.md]

By default, AutoML selects an imputation method based on the column type and content. If you specify a non-default imputation method, AutoML does not perform [Semantic Type Detection](/concepts/semantic-type-detection.md). ^[data-preparation-for-forecasting-databricks-on-aws.md]

## Split Forecasting Data into Train, Validation, and Test Sets

AutoML splits your data into three splits for training, validation, and testing. ^[data-preparation-for-forecasting-databricks-on-aws.md]

For forecasting tasks, AutoML uses [Time Series Cross-Validation](/concepts/time-series-cross-validation.md). This method incrementally extends the training dataset chronologically and performs validation on subsequent time points. Cross-validation provides a robust evaluation of a model's performance over different segments of time, ensuring that the forecasting model is rigorously tested against unseen future data and maintaining the relevance and accuracy of predictions. ^[data-preparation-for-forecasting-databricks-on-aws.md]

The number of cross-validation folds depends on input table characteristics such as the number of time series, the presence of covariates, and the time series length. ^[data-preparation-for-forecasting-databricks-on-aws.md]

## Time Series Aggregation

For forecasting problems, when there are multiple values for a timestamp in a time series, AutoML uses the average of the values by default. ^[data-preparation-for-forecasting-databricks-on-aws.md]

To use the sum instead, edit the source code notebook generated by the trial runs. In the **Aggregate data by …** cell, change `.agg(y=(target_col, "avg"))` to `.agg(y=(target_col, "sum"))`, as shown:

```python
group_cols = [time_col] + id_cols
df_aggregation = df_loaded \
    .groupby(group_cols) \
    .agg(y=(target_col, "sum")) \
    .reset_index() \
    .rename(columns={ time_col: "ds" })
```

^[data-preparation-for-forecasting-databricks-on-aws.md]

## Related Concepts

- AutoML – The automated machine learning framework that prepares data for forecasting.
- Time Series Analysis – The underlying methodology for forecasting tasks.
- [Cross-Validation for Time Series](/concepts/rolling-window-backtesting.md) – The validation technique used to evaluate forecasting models.
- [Semantic Type Detection](/concepts/semantic-type-detection.md) – AutoML's ability to infer column types, which is disabled when using non-default imputation.
- AutoML API Reference – The Python API for configuring data preparation settings.
- Forecasting Train API – The API endpoint for configuring forecasting training parameters.
- Notebook Generation – How AutoML generates notebooks that can be edited for custom aggregation.

## Sources

- data-preparation-for-forecasting-databricks-on-aws.md

# Citations

1. [data-preparation-for-forecasting-databricks-on-aws.md](/references/data-preparation-for-forecasting-databricks-on-aws-d40acbea.md)
