tbillprice

Price Treasury bill

Description

example

Price = tbillprice(Rate,Settle,Maturity) computes the price of a Treasury bill given a yield or discount rate.

example

Price = tbillprice(___,Type) adds an optional argument for Type.

Examples

collapse all

Given a Treasury bill with the following characteristics, compute the price of the Treasury bill using the bond-equivalent yield (Type = 2) as input.

Rate = 0.045;
Settle = '01-Oct-02';
Maturity = '31-Mar-03';

Type = 2;

Price = tbillprice(Rate, Settle, Maturity, Type)
Price = 97.8172

Use tbillprice to price a portfolio of Treasury bills.

Rate = [0.045; 0.046];
Settle = {'02-Jan-02'; '01-Mar-02'};
Maturity = {'30-June-02'; '30-June-02'};
Type = [2 3];

Price = tbillprice(Rate, Settle, Maturity, Type)
Price = 2×1

97.8408
98.4539

Use tbillprice to price a portfolio of Treasury bills using datetime input.

Rate = [0.045; 0.046];
Type = [2 3];

Settle = datetime({'2002-01-02';'2002-03-01'},'InputFormat','yyyy-MM-dd','Locale','en_US');
Maturity = datetime({'2002-06-30';'2002-06-30'},'InputFormat','yyyy-MM-dd','Locale','en_US');
Price = tbillprice(Rate, Settle, Maturity, Type)
Price = 2×1

97.8408
98.4539

Input Arguments

collapse all

Bond-equivalent yield, money-market yield, or discount rate (defined by the input Type), specified as a scalar of a NTBILLS-by-1 vector of decimal values.

Data Types: double

Settlement date of the Treasury bill, specified as a scalar or a NTBILLS-by-1 vector of serial date numbers, date character vectors, or datetime arrays.

Data Types: double | char | datetime

Maturity date of the Treasury bill, specified as a scalar or a NTBILLS-by-1 vector of serial date numbers, date character vectors, or datetime arrays.

Data Types: double | char | datetime

Rate type (determines how to interpret values entered in Rate), specified as a numeric value of 1,2, or 3 using a scalar or a NTBILLS-by-1 vector.

Note

The bond-equivalent yield basis is actual/365. The money-market yield basis is actual/360. The discount rate basis is actual/360.

Data Types: double

Output Arguments

collapse all

Treasury bill prices for every \$100 face, returned as a NTBILLS-by-1 vector.

 SIA Fixed Income Securities Formulas for Price, Yield, and Accrued Interest. Volume 1, 3rd edition, pp. 44–45.

 Krgin, D. Handbook of Global Fixed Income Calculations. Wiley, 2002.

 Stigum, M., Robinson, F. Money Market and Bond Calculation. McGraw-Hill, 1996.