File Exchange

image thumbnail

Monte Carlo example of a Multi Commodity Spot and Forward curves Simulator

version 1.1.0.0 (1.04 MB) by Ahmos Sansom
Implementation of a commodity spot and Multi-Factor forward curve simulator for coupled markets

3 Downloads

Updated 29 Sep 2015

View Version History

View License

1. Introduction
The attached matlab code simulates future coupled spot and forward curves based on the Carlos Blanco and Michael Pierce model published in Energy Risk, May 2012; the forward curve simulator is based on the Clewlow and Strickland model detailed in [2] and the submission in June 2013. The aim of the code is to simulate several commodity markets of spot and forward simulations.
2. Running the code
The script:
SpotModelExample.m

can be run to show how to the model is initialised that will output several figures highlighting simulations and validation.

The main engine determining the simulated spot and forward curves:

SpotandMultiFactorForwardCurveSimulator.m

3. References

[1] “Joint Simulation of Spot Prices and Forward Curves,” Carlos Blanco and Michael Pierce, Energy Risk, May 2012

[2] "Multi-Factor Mult-Commodity models & Parameter Estimation Processess,” John Breslin, Les Clewlow, Chris Strickland, Daniel van der Zee, Lacima, 2008.

Cite As

Ahmos Sansom (2021). Monte Carlo example of a Multi Commodity Spot and Forward curves Simulator (https://www.mathworks.com/matlabcentral/fileexchange/48070-monte-carlo-example-of-a-multi-commodity-spot-and-forward-curves-simulator), MATLAB Central File Exchange. Retrieved .

Comments and Ratings (5)

Ahmos Sansom

Updated with missing file.

Konstantinos Sofos

Thanks for sharing. You miss from the attachments the function GetCov.

Ahmos Sansom

Hi Ben,

Looks like you're missing a toolbox, probably the optimisation or statistics one.

Thanks

I have
>> ver
----------------------------------------------------------------------------------------------------
MATLAB Version: 8.5.0.197613 (R2015a)
MATLAB License Number: 461048
Operating System: Microsoft Windows 8.1 Enterprise Version 6.3 (Build 9600)
Java Version: Java 1.7.0_60-b19 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode
----------------------------------------------------------------------------------------------------
MATLAB Version 8.5 (R2015a)
Database Toolbox Version 5.2.1 (R2015a)
Econometrics Toolbox Version 3.2 (R2015a)
Financial Toolbox Version 5.5 (R2015a)
Optimization Toolbox Version 7.2 (R2015a)
Statistics and Machine Learning Toolbox Version 10.0 (R2015a)

Ahmos Sansom

Hi Ben,

Looks like you're missing a toolbox, probably the optimisation or statistics one.

Thanks

I have
>> ver
----------------------------------------------------------------------------------------------------
MATLAB Version: 8.5.0.197613 (R2015a)
MATLAB License Number: 461048
Operating System: Microsoft Windows 8.1 Enterprise Version 6.3 (Build 9600)
Java Version: Java 1.7.0_60-b19 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode
----------------------------------------------------------------------------------------------------
MATLAB Version 8.5 (R2015a)
Database Toolbox Version 5.2.1 (R2015a)
Econometrics Toolbox Version 3.2 (R2015a)
Financial Toolbox Version 5.5 (R2015a)
Optimization Toolbox Version 7.2 (R2015a)
Statistics and Machine Learning Toolbox Version 10.0 (R2015a)

Ben Gatley

Hi,

I tried running this but got got;

Error in SpotModelExample (line 43)
[initFCs, volFNsCorrs, AllVolFNs ] = CalibrateFCModel(FCData, nFactors);

Can you help?

Thanks,

Ben

MATLAB Release Compatibility
Created with R2012b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!