Dissertation · BSc Computer Science (AI) · 2021–25
Combining deep neural networks and machine learning to forecast financial markets
My final-year research at Heriot-Watt University Dubai. Scroll to walk through it, chapter by chapter.

“Who can make the muddy water clear? Let it be still, and it will gradually become clear.”
Can an accurate model also be a profitable one?
Most forecasting research optimises error metrics such as RMSE and R². This study evaluated models on both predictive accuracy and their returns in simulated trading.
Why it matters
Models judged on accuracy alone can score well and still lose money once deployed. Evaluating forecasts against financial outcomes ties model performance directly to profit and loss, and gives leaders a sound basis for investment decisions.
Two decades of market data
Hourly EUR/USD price data from 2003 to 2024, enriched with engineered technical indicators. Time-series cross-validation with a sliding window kept every test strictly on data the model had never seen.
Why it matters
Look-ahead bias and overfitting are leading reasons strategies that excel in backtests fail in live markets. Validating strictly on future data reduces the risk of committing capital to results that cannot be repeated.
Every architecture, head to head
Recurrent neural networks (GRU and LSTM), Transformers, Bayesian variants and hybrid models were benchmarked against each other, alongside gradient-boosted trees for predicting market direction.
Why it matters
Systematic benchmarking ensures the chosen model is selected on evidence. It also avoids investing in complex architectures where simpler models perform as well, lowering compute, maintenance and model-risk costs.
Close price · forecast accuracy
Market direction · reliability
Two specialists and a risk manager
The final system splits the problem. An XGBoost classifier predicts market direction, a GRU-LSTM network forecasts the closing price, and the Kelly Criterion sizes each position according to the model's confidence.
Why it matters
Assigning each task to the best-suited model improves overall reliability. Confidence-based position sizing limits exposure when signals are weak, protecting capital in volatile periods while preserving upside when conviction is high.
A 29% return on unseen market data
In out-of-sample backtesting, short holding periods were dominated by market noise, while a longer decision horizon delivered a 29% return.
Why it matters
Short holding periods mean more frequent trading, which increases transaction costs and exposure to noise. Aligning the decision horizon with the strength of the signal preserved returns, a principle that applies to any business acting on model predictions.
accumulated multi-timeframe test
Findings
What the research found
Hybrid architectures generalise better than single models
Combining deep neural networks with gradient-boosted models produced more stable results across time-series validation than any single architecture.
Problem framing and feature engineering outweigh model complexity
Choosing the right prediction target and engineering the right features mattered more than adding model complexity.
Decision horizon drives returns
With confidence-based position sizing, short horizons were lost to market noise, while longer horizons delivered a 29% return on out-of-sample data.