Documentation

This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

tbl2bond

Treasury bond parameters given Treasury bill parameters

Syntax

[TBondMatrix, Settle] = tbl2bond(TBillMatrix)

Arguments

TBillMatrix

Treasury bill parameters can be a n-by-5 matrix or a n-by-5 table. If TBillMatrix is an n-by-5 table, the first column represents Maturity dates and these dates can be serial date numbers, date character vectors, or datetime arrays. If TBillMatrix is an n-by-5 matrix where each row describes a Treasury bill. n is the number of Treasury bills. Columns are [Maturity DaysMaturity Bid Asked AskYield] where:

Maturity

Maturity date serial date number. Use datenum to convert date character vectors to serial date numbers. If TBillMatrix is an n-by-5 table, the first column represents Maturity dates and these dates can be serial date numbers, date character vectors, or datetime arrays.

DaysMaturity

Days to maturity, as an integer. Days to maturity is quoted on a skip-day basis; the actual number of days from settlement to maturity is DaysMaturity + 1.

Bid

Bid bank-discount rate: the percentage discount from face value at which the bill could be bought, annualized on a simple-interest basis. A decimal fraction.

Asked

Asked bank-discount rate, as a decimal fraction.

AskYield

Asked yield: the bond-equivalent yield from holding the bill to maturity, annualized on a simple-interest basis and assuming a 365-day year. A decimal fraction.

Description

[TBondMatrix, Settle] = tbl2bond(TBillMatrix) restates U.S. Treasury bill market parameters in U.S. Treasury bond form as zero-coupon bonds. This function makes Treasury bills directly comparable to Treasury bonds and notes.

TBondMatrix

Treasury bond parameters. If the input TBillMatrix is a table, then TBondmatrix is returned as a table. In this case, the second column, representing Maturity dates, will be the same class used for Maturity dates in the input matrix. For example, if Maturity dates are datetime arrays in TBillMatrix, they will also be datetime arrays in TBondMatrix. The columns of TBondMatrix are [CouponRate Maturity Bid Asked AskYield] where

CouponRate

Coupon rate, which is always 0.

Maturity

Maturity date, as a serial date number. This date is the same as the Treasury bill Maturity date. If Maturity dates are datetime arrays in TBillMatrix, they will also be datetime arrays in TBondMatrix

Bid

Bid price based on $100 face value.

Asked

Asked price based on $100 face value.

AskYield

Asked yield to maturity: the effective return from holding the bond to maturity, annualized on a compound-interest basis.

Settle

N-by-1 vector of settlement dates implied by the maturity dates and the number of days to maturity quote. Settle will be in serial date number by default. Settle will be returned as a datetime array only if the input TBillMatrix is a table containing datetime arrays for Maturity in the first column.

Examples

collapse all

This example shows how to restate U.S. Treasury bill market parameters in U.S. Treasury bond form, given published Treasury bill market parameters for December 22, 1997.

TBill = [datenum('jan 02 1998')  10  0.0526  0.0522  0.0530
         datenum('feb 05 1998')  44  0.0537  0.0533  0.0544
         datenum('mar 05 1998')  72  0.0529  0.0527  0.0540];

TBond = tbl2bond(TBill)
TBond =

   1.0e+05 *

         0    7.2976    0.0010    0.0010    0.0000
         0    7.2979    0.0010    0.0010    0.0000
         0    7.2982    0.0010    0.0010    0.0000

This example shows how to use datetime input to restate U.S. Treasury bill market parameters in U.S. Treasury bond form, given published Treasury bill market parameters for December 22, 1997.

TBill = [datenum('jan 02 1998')  10  0.0526  0.0522  0.0530
         datenum('feb 05 1998')  44  0.0537  0.0533  0.0544
         datenum('mar 05 1998')  72  0.0529  0.0527  0.0540];

dates = datetime(TBill(:,1), 'ConvertFrom', 'datenum','Locale','en_US');
data = TBill(:,2:end);
t=[table(dates) array2table(data)];
[TBond, Settle] = tbl2bond(t)
TBond = 

    CouponRate     Maturity       Bid      Asked     AskYield
    __________    ___________    ______    ______    ________

    0             02-Jan-1998    99.854    99.855     0.053  
    0             05-Feb-1998    99.344    99.349    0.0544  
    0             05-Mar-1998    98.942    98.946     0.054  


Settle = 

  3×1 datetime array

   22-Dec-1997
   22-Dec-1997
   22-Dec-1997

Related Examples

See Also

|

Introduced before R2006a

Was this topic helpful?