Documentation Center

  • Trial Software
  • Product Updates

instcap

Construct cap instrument

Syntax

InstSet = instcap(InstSet, Strike, Settle, Maturity, Reset,
Basis, Principal)
[FieldList, ClassList, TypeString] = instcap

Arguments

InstSet

Instrument variable. This argument is specified only when adding cap instruments to an existing instrument set. See instget for more information on the InstSet variable.

Strike

Rate at which the cap is exercised, as a decimal number.

Settle

Settlement date. Serial date number representing the settlement date of the cap.

Maturity

Serial date number representing the maturity date of the cap.

Reset

(Optional) NINST-by-1 vector representing the frequency of payments per year. Default = 1.

Basis

(Optional) Day-count basis of the instrument. A vector of integers.

  • 0 = actual/actual (default)

  • 1 = 30/360 (SIA)

  • 2 = actual/360

  • 3 = actual/365

  • 4 = 30/360 (BMA)

  • 5 = 30/360 (ISDA)

  • 6 = 30/360 (European)

  • 7 = actual/365 (Japanese)

  • 8 = actual/actual (ICMA)

  • 9 = actual/360 (ICMA)

  • 10 = actual/365 (ICMA)

  • 11 = 30/360E (ICMA)

  • 12 = actual/actual (ISDA)

  • 13 = BUS/252

For more information, see basis.

Principal

(Optional) The notional principal amount. Default = 100.

Description

InstSet = instcap(InstSet, Strike, Settle, Maturity, Reset,
Basis, Principal)
creates a new instrument set containing cap instruments or adds cap instruments to an existing instrument set.

[FieldList, ClassList, TypeString] = instcap displays the classes.

FieldList is a number of fields (NFIELDS)-by-1 cell array of strings listing the name of each data field for this instrument type.

ClassList is an NFIELDS-by-1 cell array of strings listing the data class of each field. The class determines how arguments are parsed. Valid strings are 'dble', 'date', and 'char'.

TypeString is a string specifying the type of instrument added. For a cap instrument, TypeString = 'Cap'.

Examples

expand all

Create Two Cap Instruments

Create a new instrument variable with the following information:

Strike = [0.035; 0.045];
Settle= 'Jan-1-2013';
Maturity = 'Jan-1-2014';
Reset = 1;
Basis = 1;
Principal = 1000;

Create the new cap instruments.

InstSet = instcap(Strike, Settle, Maturity, Reset, Basis, Principal)
InstSet = 

        FinObj: 'Instruments'
    IndexTable: [1x1 struct]
          Type: {'Cap'}
     FieldName: {{6x1 cell}}
    FieldClass: {{6x1 cell}}
     FieldData: {{6x1 cell}}

Display the cap instruments.

instdisp(InstSet)
Index Type Strike Settle         Maturity       CapReset Basis Principal
1     Cap  0.035  01-Jan-2013    01-Jan-2014    1        1     1000     
2     Cap  0.045  01-Jan-2013    01-Jan-2014    1        1     1000     
 

See Also

| | | | | |

Was this topic helpful?