| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Financial Derivatives Toolbox |
| Contents | Index |
| Learn more about Financial Derivatives Toolbox |
PriceSens = basketsensbyju(RateSpec, BasketStockSpec,
OptSpec, Strike,
Settle, Maturity)
PriceSens = basketsensbyju(RateSpec, BasketStockSpec,
OptSpec, Strike,
Settle, Maturity, 'ParameterName', ParameterValue ...)
PriceSens = basketsensbyju(RateSpec, BasketStockSpec, OptSpec, Strike, Settle, Maturity) calculates prices and sensitivities for basket options using the Nengjiu Ju approximation model.
PriceSens = basketsensbyju(RateSpec, BasketStockSpec, OptSpec, Strike, Settle, Maturity, 'ParameterName', ParameterValue ...) accepts optional inputs as one or more comma-separated parameter/value pairs. 'ParameterName' is the name of the parameter inside single quotes. 'ParameterValue is the value corresponding to 'ParameterName'. Specify parameter-value pairs in any order. Names are case-insensitive and partial string matches are allowable, if no ambiguities exist.
RateSpec |
Annualized, continuously compounded rate term structure. For more information on the interest rate specification, see intenvset. |
BasketStockSpec |
BasketStock specification. For information on the basket of stocks specification, see basketstockspec. |
OptSpec |
String or 2-by-1 cell array of the strings 'call' or 'put'. |
Strike |
Scalar of the option strike price. |
Settle |
Scalar of the settlement or trade date specified as a string or serial date number. |
Maturity |
Maturity date, specified as a string or serial date number. |
OutSpec |
Parameter value is an NOUT-by-1 or 1-by-NOUT cell array of strings indicating the nature and order of the outputs for the function. Possible values are 'Price', 'Delta', 'Gamma', 'Vega', 'Lambda', 'Rho', 'Theta', and 'All'. For example, OutSpec = {'Price', 'Lamba', 'Rho'} specifies that the output is Price, Lambda, and Rho, in that order. OutSpec = {'All'} specifies that the output should be Delta, Gamma, Vega, Lambda, Rho, Theta, and Price, in that order. This is the same as specifying OutSpec as OutSpec = {'Delta', 'Gamma', 'Vega', 'Lambda', 'Rho', 'Theta', 'Price'};. Default: OutSpec = {'Price'} |
UndIdx |
Scalar of the indice of the underlying instrument to compute the sensitivity. Default: UndIdx = [] |
PriceSens |
Expected prices or sensitivities values for the basket option. |
Find a European call basket option of five stocks. Assume that the basket contains:
5% of the first stock trading at $110
15% of the second stock trading at $75
20% of the third stock trading at $40
25% of the fourth stock trading at $125
35% of the fifth stock trading at $92
These stocks have annual volatilities of 20% and the correlation between the assets is zero. On May 1, 2009, an investor wants to buy a 1-year call option with a strike price of $90. The current annualized, continuously compounded interest is 5%. Use this data to compute price and delta of the call basket option with the Ju approximation model.
Settle = 'May-1-2009';
Maturity = 'May-1-2010';
% Define RateSpec
Rate = 0.05;
Compounding = -1;
RateSpec = intenvset('ValuationDate', Settle, 'StartDates', ...
Settle, 'EndDates', Maturity, 'Rates', Rate, 'Compounding', Compounding);
% Define the Correlation matrix. Correlation matrices are symmetric, and
% have ones along the main diagonal.
NumInst = 5;
InstIdx = ones(NumInst,1);
Corr = diag(ones(5,1), 0);
% Define BasketStockSpec
AssetPrice = [110; 75; 40; 125; 92];
Volatility = 0.2;
Quantity = [0.05; 0.15; 0.2; 0.25; 0.35];
BasketStockSpec = basketstockspec(Volatility, AssetPrice, Quantity, Corr);
% Compute the price of the call basket option. Calculate also the delta
% of the first stock.
OptSpec = {'call'};
Strike = 90;
OutSpec = {'Price','Delta'};
UndIdx = 1; % First element in the basket
[Price, Delta] = basketsensbyju(RateSpec, BasketStockSpec, OptSpec, Strike, Settle, ...
Maturity, 'OutSpec', OutSpec,'UndIdx', UndIdx)This returns:
Price = 5.16098 Delta = 0.02972
Compute Delta with respect to the second asset:
UndIdx = 2; % Second element in the basket
OutSpec = {'Delta'};
Delta = basketsensbyju(RateSpec, BasketStockSpec, OptSpec, Strike, Settle, Maturity, ...
'OutSpec',OutSpec,'UndIdx',UndIdx)
Delta =
0.09063Nengjiu Ju, "Pricing Asian and Basket Options Via Taylor Expansion", Journal of Computational Finance, Vol. 5, 2002.
![]() | basketbyls | basketsensbyls | ![]() |
View demos and recorded presentations led by industry experts.
Now On Demand
Network with industry peers and learn the latest applications of the leading software product for computational finance.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |