%% Retrieve Instrument from Instrument Set
% Retrieve the instrument set variable ExampleInst from the data file InstSetExamples.mat. ExampleInst contains three types of instruments: Option, Futures, and TBill.

load InstSetExamples; 
instdisp(ExampleInst)

% Create a swap instrument and use instdisp to display the instrument. Notice that value of NaN in two columns for this instrument indicates that the default values for LegReset and LegType parameters will be used in the swap instrument’s pricing function.

LegRate1 = [0.065, 0];
Settle1 = datenum('jan-1-2007');
Maturity1 = datenum('jan-1-2012');

ISet = instswap(LegRate1, Settle1, Maturity1);
instdisp(ISet) 

% Copyright 2020 The MathWorks, Inc.