Main Content

instbond

Construct bond instrument

Description

InstSet = instbond(CouponRate,Settle,Maturity) creates a new instrument set containing Bond instruments.

example

InstSet = instbond(InstSet,CouponRate,Settle,Maturity) adds Bond instruments to an existing instrument set.

example

[FieldList,ClassList,TypeString] = instbond lists field meta-data for the Bond instrument.

example

Examples

collapse all

Create a new instrument variable with the following information:

CouponRate= [0.035;0.04];
Settle= datetime(2013,11,1); 
Maturity = datetime(2014,11,1); 
Period =1; 

InstSet = instbond(CouponRate, Settle, Maturity, ...
Period)
InstSet = struct with fields:
        FinObj: 'Instruments'
    IndexTable: [1x1 struct]
          Type: {'Bond'}
     FieldName: {{1x1 cell}}
    FieldClass: {{1x1 cell}}
     FieldData: {{1x1 cell}}

Display the instrument set.

instdisp(InstSet)
Index Type CouponRate Settle         Maturity       Period Basis EndMonthRule IssueDate FirstCouponDate LastCouponDate StartDate Face
1     Bond 0.035      01-Nov-2013    01-Nov-2014    1      0     1            NaN       NaN             NaN            NaN       100 
2     Bond 0.04       01-Nov-2013    01-Nov-2014    1      0     1            NaN       NaN             NaN            NaN       100 
 

Input Arguments

collapse all

Instrument variable, specified only when adding Bond instruments to an existing instrument set. For more information on the InstSet variable, see instget.

Data Types: struct

Coupon rate indicating the annual percentage rate, specified as an NINST-by-1 vector or an NINST-by-1 cell array of decimal annual rates, or decimal annual rate schedules. For the latter case of a variable coupon schedule, each element of the cell array is a NumDates-by-2 cell array, where the first column is dates and the second column is its associated rate. The date indicates the last day that the coupon rate is valid.

Data Types: double | cell

Settlement dates, specified as scalar or an NINST-by-1 vector using a datetime array, string array, or date character vectors.

Note

Settle must be earlier than Maturity.

To support existing code, instbond also accepts serial date numbers as inputs, but they are not recommended.

Maturity dates, specified as scalar or an NINST-by-1 vector using a datetime array, string array, or date character vectors.

To support existing code, instbond also accepts serial date numbers as inputs, but they are not recommended.

(Optional) Coupons per year, specified as a scalar or an NINST-by-1 vector. Values for Period are 1, 2, 3, 4, 6, and 12.

Data Types: double

(Optional) Day-count basis, specified as scalar or an NINST-by-1 vector.

  • 0 = actual/actual

  • 1 = 30/360 (SIA)

  • 2 = actual/360

  • 3 = actual/365

  • 4 = 30/360 (PSA)

  • 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/365 (ISDA)

  • 13 = BUS/252

For more information, see Basis.

Data Types: double

(Optional) End-of-month rule flag for generating dates when Maturity is an end-of-month date for a month having 30 or fewer days, specified as a scalar or a nonnegative integer [0, 1] using an NINST-by-1 vector.

  • 0 = Ignore rule, meaning that a bond's coupon payment date is always the same numerical day of the month.

  • 1 = Set rule on, meaning that a bond's coupon payment date is always the last actual day of the month.

Data Types: logical

(Optional) Bond issue date, specified as a scalar or an NINST-by-1 vector using a datetime array, string array, or date character vectors.

To support existing code, instbond also accepts serial date numbers as inputs, but they are not recommended.

(Optional) Irregular first coupon date, specified as a scalar or an NINST-by-1 vector using a datetime array, string array, or date character vectors.

To support existing code, instbond also accepts serial date numbers as inputs, but they are not recommended.

When FirstCouponDate and LastCouponDate are both specified, FirstCouponDate takes precedence in determining the coupon payment structure. If you do not specify a FirstCouponDate, the cash flow payment dates are determined from other inputs.

(Optional) Irregular last coupon date, specified as a scalar or an NINST-by-1 vector using a datetime array, string array, or date character vectors.

To support existing code, instbond also accepts serial date numbers as inputs, but they are not recommended.

In the absence of a specified FirstCouponDate, a specified LastCouponDate determines the coupon structure of the bond. The coupon structure of a bond is truncated at the LastCouponDate, regardless of where it falls, and is followed only by the bond's maturity cash flow date. If you do not specify a LastCouponDate, the cash flow payment dates are determined from other inputs.

Forward starting date of payments (the date from which a bond cash flow is considered), specified as a scalar or an NINST-by-1 vector using a datetime array, string array, or date character vectors.

To support existing code, instbond also accepts serial date numbers as inputs, but they are not recommended.

If you do not specify StartDate, the effective start date is the Settle date.

(Optional) Face or par value, specified as a scalar or an NINST-by-1 vector of nonnegative face values or an NINST-by-1 cell array of face values or face value schedules. For the latter case, each element of the cell array is a NumDates-by-2 cell array, where the first column is dates and the second column is its associated face value. The date indicates the last day that the face value is valid.

Data Types: cell | double

Output Arguments

collapse all

Variable containing a collection of instruments, returned as a structure. Instruments are broken down by type and each type can have different data fields. Each stored data field has a row vector or string for each instrument. For more information on the InstSet variable, see instget.

Name of each data field for a Bond instrument, returned as an NFIELDS-by-1 cell array of character vectors.

Data class for each field, returned as an NFIELDS-by-1 cell array of character vectors. The class determines how arguments are parsed. Valid character vectors are 'dble', 'date', and 'char'.

Type of instrument, returned as a character vector. For a Bond instrument, TypeString = 'Bond'.

Version History

Introduced before R2006a

expand all