Research result
No signal foundBrent crude: Granger-screened neural network
Brent crude futures · weeklyWeekly panel to September 2026 · 465-parameter network
Only one of four candidate variables passed the causality screen, and the network built on it did no better than always guessing the majority direction.
- Hypothesis tested
- Macroeconomic and geopolitical variables predict the weekly direction of Brent, and a small neural network can turn them into a significant signal on unseen data.
- Result
- Not supported. One of four variables passed the causality screen. The network's accuracy was 52.8%, below the 53.7% from always guessing the majority direction, and the luck test gave p = 0.592.
- How it was tested
- Tested on unseen data
- No future data used
- Luck test
- Test accuracy
- 52.8%
- Permutation p-value
- 0.592
- IC in the clean folds
- −0.054, −0.021
- Variables admitted
- 1 of 4
- Real-model IC (permutation run)
- −0.014
- Network parameters
- 465
majority-class baseline 53.7%
folds 4 and 5
Jupyter notebook: API keys removed.
This is the full report behind the summary above. Every number is an actual output of the study's code, including a data defect that was found in the pipeline and is reported in full below.
1. Hypothesis and approach
Crude oil markets, and Brent crude in particular, are commonly understood to respond to macroeconomic conditions and to geopolitical risk. Real interest rates change the cost of holding oil in storage. The strength of the US dollar changes the price of a dollar-priced commodity for buyers who use other currencies. Industrial production is a proxy for global demand. Geopolitical events threaten supply directly.
The aim of this study is to find out, with a formal statistical procedure and not by looking at charts or at correlation alone, whether this kind of relationship can forecast the direction of Brent returns each week.
The method rests on one principle. Correlation between a candidate variable and the price is not enough reason to put that variable into a forecasting model. A variable is admitted only if it passes a formal test of Granger causality with respect to future returns. This separates two questions: which variables carry information about the future, and how to combine them. It also lowers the risk that a model fits variables that merely move together with the price at the same time, and say nothing about where the price goes next.
1.1 Hypothesis
Let be the log-return of Brent in week , that is , the change in the logarithm of the weekly price. Let be a vector of candidate macroeconomic and geopolitical variables observed in week .
H1 (working hypothesis). There is a non-empty subset of the candidate variables, with a lag for each variable in , such that the variables in Granger-cause . In addition, a small neural network that takes the lagged values for as input can produce an output whose correlation with next week's direction is not zero on data that was not used to fit it:
Here equals 1 if next week's return is positive and 0 otherwise. The network output is a number between 0 and 1. On held-out data this correlation is called the information coefficient (IC). A value near zero means no relationship. The test is two-sided: it checks against , at significance level .
H0 (null hypothesis). No such subset, lag structure and function exist. Any correlation between the model's output and the future direction on held-out data is no larger in size than a model with no real predictive relationship would produce by chance.
Granger causality needs a short explanation. A variable Granger-causes another if its past values help to predict the other variable, beyond what the other variable's own past already predicts. It is a statement about prediction. It does not prove that one variable truly causes the other.
1.2 The five stages
The study runs in five steps, one after the other.
- Data acquisition: collect the Brent price and the candidate variables on a common weekly grid.
- Granger screening: test each candidate variable and keep only those that pass.
- Feature construction: turn the surviving variables into a lagged, normalized input, and build the target.
- Model training: fit a small multilayer perceptron (MLP), a neural network built from layers of simple units.
- Statistical validation: a chronological test split, a walk-forward test, and a permutation test on the model's information coefficient.
2. Data
2.1 Sources and sampling
Six series were collected at their native frequency and resampled to a common weekly grid, anchored to Friday. They are the Brent price and five candidate explanatory variables.
| Variable | Series identifier | Source |
|---|---|---|
| Brent crude futures, close | BZ=F | Yahoo Finance |
| Real interest rate, 10-year | DFII10 | Federal Reserve Economic Data (FRED) |
| US dollar trade-weighted index | DTWEXBGS | FRED |
| Industrial production index | INDPRO | FRED |
| Commercial crude oil stocks, excluding the US Strategic Petroleum Reserve | WCESTUS1 | US Energy Information Administration |
| Geopolitical risk index | GPRD | Caldara and Iacoviello (2022) |
Level series were forward-filled to the weekly grid between their native observations. This means a value is carried forward until the next one arrives. The price series was sampled as the last available observation within each week.
2.2 Coverage
The intended sample window began on 2010-01-01. In the panel that was actually built, the window reaches back to 1985. The reason is that the geopolitical risk series, whose own coverage begins in 1985, was merged in without being cut to match the other series. The panel has 2,177 weekly observations. Table 1 gives the number of non-missing values for each variable.
| Variable | Non-null observations | Coverage |
|---|---|---|
| Brent close | 872 | 40.1% |
| Real rate, 10-year | 846 | 38.9% |
| US dollar index | 846 | 38.9% |
| Industrial production | 30 | 1.4% |
| Crude stocks | 872 | 40.1% |
| Geopolitical risk index | 2,177 | 100.0% |
Table 1. Non-null coverage per variable, out of 2,177 weekly rows.
The industrial production series had too little coverage to support a stationarity test. It was excluded before causal screening.
2.3 A defect in target construction
When the executed pipeline was inspected, a defect was found in how the prediction target was built. It changes how part of the results in Section 7 must be read.
The target is
where is the Brent close. For weeks before Brent futures data begins, is undefined: there is no price to take a return from.
Under standard floating-point rules and the comparison rules of pandas (the data library used), the test "NaN is greater than 0" returns False. It does not return a missing value. NaN stands for "not a number", a missing value. So the target rule gives to every week with no price, and does not exclude those weeks.
The single feature that survived screening (Section 4) has data back to 1985. So these weeks were not removed by the later step that drops rows with missing values. They stayed in the training data and in the walk-forward data. Section 5 and Section 7.3 show what this did.
3. Method
3.1 Making the series stationary
A series is stationary when its average level and its spread do not drift over time. Prices usually are not stationary. Changes in prices usually are. Let be a candidate series for .
When is positive for every in the sample, a logarithmic first difference is used:
When can take zero or negative values, as the real interest rate can, a simple first difference is used:
3.2 Checking stationarity
Each transformed series was checked with the Augmented Dickey–Fuller (ADF) test. For a series , the test regression is
and the test statistic is
This statistic is compared with the Dickey–Fuller distribution, not with a standard t-distribution. The null hypothesis is , which means the series has a unit root (shocks never fade). The alternative is that is below zero, which means the series is stationary. A transformed series was accepted as stationary at p below 0.05. All four series that had enough data and went on to the Granger screen passed this check.
3.3 Granger causality
Let be the Brent log-return and a candidate variable, both stationary. Granger causality of by at lag is tested by comparing two regressions. The restricted model uses only past returns:
The unrestricted model adds past values of the candidate variable:
Let and be the residual sums of squares of the two models. The joint restriction is tested with the F-statistic
where is the number of observations used in the estimation. Rejecting the null is read as evidence that Granger-causes at lag .
For each candidate variable, lags were tested. The lag with the smallest p-value was kept. A variable was admitted to the feature set if, and only if, its smallest p-value was below 0.05.
3.4 Rolling normalization
To keep future information out of the normalization, each admitted, lagged, stationary variable was standardized with a trailing window of weeks, about one year. The value in week uses only data up to week :
4. Granger causality screening
Table 2 shows, for each of the four candidate variables that had enough data, the lag at which the Granger p-value was smallest, and whether the variable was admitted.
| Variable | Best lag (weeks) | p-value | Admitted |
|---|---|---|---|
| Geopolitical risk index | 1 | 0.0308 | Yes |
| US dollar index | 5 | 0.1190 | No |
| Crude stocks | 4 | 0.1315 | No |
| Real rate, 10-year | 5 | 0.2758 | No |
Table 2. Granger causality results at each variable's smallest-p-value lag.
Only the geopolitical risk index meets the admission rule, and it does so at a lag of one week. The chart shows the same p-values against the 0.05 line.
Granger causality screen: smallest p-value per variable
- Geopolitical risk (lag 1)0.0308
- USD index (lag 5)0.1190
- Crude stocks (lag 4)0.1315
- Real rate, 10y (lag 5)0.2758
p = 0.05
Remark: multiple comparisons. The screening was set up for five candidate variables, each tested at eight lags, which is 40 tests. Industrial production was dropped for lack of data before any test, so four variables were actually tested: 4 × 8 = 32 tests of the F-test form above, with no correction for the number of tests. (The report counts the 40 of the original design.) Suppose that no candidate variable truly Granger-causes Brent returns at any lag. Then the expected number of false positives at is 32 × 0.05 = 1.6. One nominally significant result is therefore consistent with a false positive. It does not rule one out.
5. Feature construction and target
After screening, the input to the model is a single number per week. It is the geopolitical risk index, made stationary as in Section 3.1, shifted by its admitted lag of one week, and standardized with the 52-week rolling window of Section 3.4.
Rows without enough history for the lag and the rolling window were removed. This leaves 2,150 observations. They were split in time order, with no shuffling, into a training set and a held-out test set.
| Partition | Observations | Interval |
|---|---|---|
| Training | 1,720 | 1985-07-12 to 2018-06-22 |
| Test | 430 | 2018-06-29 to 2026-09-18 |
Table 3. Chronological train and test partition of the feature set.
The training set is imbalanced. The positive class (next week's return is positive) is 13.31% of the observations. Part of this imbalance comes from the target defect of Section 2.3, and not from the true share of weeks with a positive return. Section 7.3 shows how the same defect affects the walk-forward folds.
6. The model
6.1 Architecture
The network takes one number as input. Dropout randomly switches off a share of the units during training (30% in the first layer, 20% in the second), which makes it harder for the network to memorize the training data. ReLU, written , is applied to each unit separately.
The output is a raw score, called a logit. The probability that next week's Brent return is positive is obtained by applying the logistic function at evaluation time only:
The parameters are . Their total number is
6.2 Loss function
Because the training classes are imbalanced (Section 5), the loss gives more weight to the positive class. It is a binary cross-entropy, a standard loss for yes-or-no targets:
Here and are the numbers of positive and negative training examples. The training positive rate is 13.31%, so and .
6.3 Optimization and regularization
The parameters are updated with Adam, a standard training method. It keeps running averages of the gradient and of its square:
and corrects them for the start-up bias:
Each parameter then moves in the direction of , with a step scaled by . The learning rate is . A weight decay of is used, which adds a small L2 penalty that pulls the weights toward zero.
Regularization, meaning the methods that limit overfitting, comes from two sources: the weight decay and the dropout. Both were chosen because the number of training observations is small relative to the size of the model.
6.4 Training procedure
Training uses full-batch gradient descent, which means every update uses all training rows, for at most 300 epochs. Early stopping ends training after 15 epochs in a row without an improvement in the loss on a validation subset. The parameters from the epoch with the lowest validation loss are then restored. The validation subset is the final 15% of the training interval, held out in time order so that the sequence of dates is preserved.
6.5 Result on the primary split
Table 4 shows the model's performance on the held-out test set, after training on the full training set. The majority-class baseline is the accuracy of a rule that always predicts the more common class.
| Metric | Value |
|---|---|
| Test accuracy | 52.79% |
| Information coefficient | 0.0465 |
| Majority-class baseline accuracy | 53.72% |
Table 4. Performance on the primary chronological test split.
The model's accuracy is below the accuracy of always predicting the majority class. The information coefficient is small and nominally positive. Sections 7 and 8 examine it further.
7. Walk-forward validation
7.1 Design
A single train and test split gives one result for out-of-sample performance. That cannot show whether the result is stable. The model was therefore retrained and re-tested on five expanding-window folds. In fold , the training set is all observations before a cut-off , and the test set is the next 358 observations. The cut-off moves forward in time from one fold to the next. Inside each fold, the last 15% of the training part is held out, in time order, for early stopping, as in Section 6.4.
7.2 Results
Table 5 gives the accuracy and the information coefficient for each of the five folds.
| Fold | Train obs. | Test obs. | Accuracy | IC |
|---|---|---|---|---|
| 1 | 360 | 358 | 100.00% | undefined |
| 2 | 718 | 358 | 100.00% | undefined |
| 3 | 1,076 | 358 | 75.14% | 0.0438 |
| 4 | 1,434 | 358 | 49.72% | −0.0543 |
| 5 | 1,792 | 358 | 54.47% | −0.0213 |
Table 5. Walk-forward results across five expanding-window folds.
The mean information coefficient is −0.0106 (standard deviation 0.0408). It is the average of the three folds where the IC can be computed. Fold 3 is partly affected by the defect (Section 7.3), so this average is not a clean number. The unweighted mean accuracy across all five folds is 75.87%. That figure is pulled up by the two folds with 100% accuracy, which are explained in Section 7.3, and should not be read as skill.
The chart shows the information coefficient for folds 3 to 5. Folds 1 and 2 are left out because their target is constant. Fold 3 is shown, but it is partly affected by the same defect (Section 7.3).
Walk-forward information coefficient by fold
- Fold 3 (partly affected)+0.044
- Fold 4 (clean)−0.054
- Fold 5 (clean)−0.021
7.3 Effect of the target defect
The IC is undefined in folds 1 and 2 because the target is constant inside those test sets. Section 2.3 explains why. Weeks before real Brent prices exist were given and were not excluded. If most of a fold's test set lies in this affected period, has the same value in every week. A correlation with a constant cannot be computed, so the IC is undefined. A model that always predicts that one value is right every time, so accuracy reaches 100% without any skill.
The 100% accuracy in folds 1 and 2 is therefore a product of the defect, not predictive skill. The report treats folds 3 to 5 as the ones to read. Our check of the dates says fold 3 is partly affected too. Brent prices start in January 2010, because the notebook's data loader sets its start date to 2010-01-01 while the geopolitical risk index in the same table reaches back to 1985. That is about row 1,278 of the 2,150 weekly feature rows (the table starts on 12 July 1985). Fold 3 tests rows 1,076 to 1,433, so about 202 of its 358 test weeks (56%) come before the first Brent price and carry the false label 0. Only folds 4 and 5 test weeks that all have prices. Their information coefficients are −0.054 and −0.021: both negative and small. That does not point to a stable directional relationship.
8. Permutation test
8.1 Design
A permutation test asks whether the IC on the primary test set (Table 4) can be told apart from what a model with no real predictive relationship would produce. Let be the IC of a model trained on the true training labels and evaluated on the true test labels.
To build the null distribution, the training labels were shuffled at random, independently, times. After each shuffle the model was retrained from a fresh start. Each retrained model was then evaluated against the true, unshuffled test labels. This gives 200 values, for . The empirical p-value is
In words, it is the share of shuffled-label models that did at least as well as the real model, with 1 added to both counts so that the p-value is never exactly zero.
8.2 Results
| Quantity | Value |
|---|---|
| Real-model accuracy | 46.98% |
| Real-model IC | −0.0136 |
| Mean IC of the null distribution | −0.0028 |
| Standard deviation of the null distribution | 0.0379 |
| Empirical p-value | 0.592 |
Table 6. Permutation test results, N = 200 permutations.
At p = 0.592, the null hypothesis cannot be rejected at any conventional significance level. A model trained on randomly shuffled labels reached an information coefficient at least as large as the real model's in about 59% of the trials.
Remark: instability across independent training runs. The real-model IC in this test (−0.0136) is different from the IC in Table 4 (0.0465), although the data, the architecture and the training procedure are identical. The accuracy also differs (46.98% here, 52.79% in Table 4). The difference comes from the random parts of training: the starting values of and which units dropout switches off. It is informative in itself. A model that captures a truly strong relationship should give similar out-of-sample estimates of in independent runs on the same data. A model that estimates a relationship close to will not.
9. Discussion
The negative result has several possible structural explanations, in addition to the data defect of Section 2.3.
First, the largest moves in Brent prices are usually linked to discrete supply events, such as coordinated production decisions or the escalation of a conflict. These show up as sudden steps in price, not as gradual drift. A model that takes smoothly lagged, rolling-normalized variables, as in Section 3.4, has no way to anticipate a sudden event of this kind.
Second, the link between macroeconomic conditions and energy prices is probably regime-dependent. The effect of real interest rates or dollar strength on oil may differ a lot depending on whether the market is focused on demand or on supply. A single fixed-lag linear relationship, as assumed in the Granger regressions of Section 3.3 and estimated over several decades, need not hold in every regime. The change of sign of the information coefficient across the walk-forward folds (Table 5) fits this explanation.
Third, predicting the weekly direction from public, lagged macroeconomic data is a demanding task. If such a relationship were both reliable and based on public information, standard market-efficiency arguments say that traders working at a higher frequency would trade it away.
Fourth, no correction for multiple tests was applied in the Granger screen (Section 4). The single admitted variable may therefore be a false positive and not a real causal relationship.
10. Conclusion
This study tested a formally stated hypothesis: that macroeconomic and geopolitical variables Granger-cause the weekly direction of Brent returns, and that a small neural network can use this to give a statistically significant out-of-sample signal.
Of five candidate variables, only the geopolitical risk index met the Granger admission rule, at a lag of one week. The resulting single-input model did worse than a majority-class baseline on the primary test split. Its mean information coefficient across the walk-forward folds was unstable and close to zero. It failed a permutation test at p = 0.592. The null hypothesis cannot be rejected.
At weekly frequency, and with the feature set used here, there is no evidence of a predictive relationship. This result, together with the data limitations in Sections 2.3 and 7.3, is reported in full as a documented negative finding. It follows the normal practice in signal research of retiring a hypothesis that fails formal out-of-sample validation.
Limitations
- Target definition. The target, as defined in Section 2.3, does not correctly exclude observations for which the return is undefined. Any later version of this analysis should define it with an explicit missing-data mask.
- One input. Only one variable survived the causal screen, so the model is univariate. This limits what could have been found, even if a true relationship existed.
- No multiplicity correction. No correction for multiple comparisons was applied at the screening stage.
- Weekly frequency only. The analysis does not address higher-frequency, event-driven behaviour.
- No backtest with trading costs. None was run. The signal does not pass the permutation test of Section 8, so a simulation weighted by capital would add no further evidence about whether the underlying hypothesis is valid.
Research by Lanre Ibrahim. Source: Neural Networks on Energy notebook and the Brent crude neural network report. Historical tests on past data; not investment advice and not the record of any managed account.