Real-data walkthrough: German electricity prices
This example uses the German electricity-price data from Improve Forecast Accuracy with TimeGPT. The target is the hourly electricity price in EUR/MWh. The future inputs are published load and generation forecasts — the kind of forward-looking information that belongs inX_df.
Step 1: Load the Data
Step 2: Simulate the Published-Input Scenario
Generate 500 possible 48-hour price paths using the published load and generation forecasts:
The result contains
1 * 500 * 48 = 24,000 rows. Rows sharing a sample_id
form one complete electricity-price trajectory.
Step 3: Simulate a Changed-Input Scenario
An energy buyer wants to understand what happens if system conditions tighten on the second day. Create a scenario with:- Load forecast 15% higher
- Generation forecast 15% lower

Lines show the median path and shaded areas show the 10th–90th percentile range. The dotted line is the price observed after the forecast origin.
Step 4: Convert the Paths into an Energy-Cost Risk
Suppose the buyer needs 1 MWh in every forecast hour. Summing each complete path gives one possible 48-hour procurement cost:
Each observation is the total cost from one complete 48-hour path.
You have compared two complete outcome distributions under different input
assumptions — the core scenario-analysis workflow.
Simulate Multiple Series Together
Pass stacked series using the normalunique_id, time, and target columns:
multivariate=True when each sample_id should represent one coherent scenario
across all series. This changes two things: the marginal forecasts become joint
for models that support it, so each series’ distribution can reflect the others,
and the sample paths are coupled so that path k describes all series at once.
Why the seed matters when comparing runs
Why the seed matters when comparing runs
Both the coupled and the per-series shuffle draw from the same generator state,
so with a fixed seed the first series by ID is reordered identically whether
multivariate is True or False — and its paths come out the same whenever its
marginal forecast is unchanged too. Varying the seed removes this overlap from
visual comparisons.coupled=False.
coupled=False is expected when multivariate=False or when the request
contains only one series. It does not indicate an error.Troubleshooting
coupled is false
Check that:
multivariate=True- More than one series is present
- All series share the same forecast origin
- Their common recent history contains a complete window