MoneyMarketBond_y





http://www.QuantTools.com
CapeTools Bonds (Yield) function list

Welcome | Documentation format | QuantTools Groups | QuantTools Categories | Licence

Key TAGs | Excel Index | API Index



Creates a MoneyMarket bond object.

The bond takes as input the Bond's yield.

This yield will be used to discount the Bond flows.

This object can be used to represent money market securities that pay interest (ie - Notes, Commercial Paper, Certificates of Deposit etc...).

A 'BondKey' string value will be returned on a successful creation of the bond object.

This string 'Key' value can then be passed to further bond functions for pricing or querying.



This function creates an object and returns a string-key value to represent this created object.
The TAG value of the string-key returned (second part of the key) is : "MMBND_Y"



Note: Within Excel, the function is named - CT.BOND.MoneyMarketBond_y




High level graphic of MoneyMarketBond_y() function with parameters. Blue square node is the actual function with the parameters ordered.



Parameter Description


  1. Key parameter

    Key Handle to be used for the new Bond object.
  2. Reload parameter

    When creating this object for the first time, set this parameter to a positive value. Within Excel, when re-computing a worksheet where you do not wish to recreate the object, set this parameter to zero (0).
  3. Ccy parameter

    The currency code that you want to associate with the Bond.
  4. SettleDate parameter

    Settlement date of the Bond.
  5. datedDate parameter

    Dated date of the bond. Date on which the bond begins to accrue interest. If you enter 0 for this parameter (or leave it blank within Excel) the datedDate will be computed internally based on the maturity date and the settlement date.
  6. matDate parameter

    Maturity date of the bond.
  7. coupon parameter

    The coupon rate.
  8. dayCounter parameter

    DayCounter to use for the bond. Used to calculate time in years.
  9. calKey parameter

    Key to an already constructed Calendar object. Used to adjust dates for holidays in the case of a true yield calculation method or where the 'exactCoupon' parameter has been set to true.
  10. BusDayConv parameter

    Business Day Convention to use.
  11. redemption parameter

    Redemption value of the bond.
  12. BondYield parameter

    The Bond's yield value.
  13. YieldQuoteFreq parameter

    The default yield to maturity quotation (for the output of yield values) frequency.
  14. YieldQMethod parameter

    Yield calculation quotation method for the instrument. Possible values are : 'Simple', 'Discount', 'ISMA' (Compounded on an Annual coupon frequency), 'Continuous' (for continuous compounding) or 'True' (Compounded on an Annual coupon frequency, but uses adjusted bond dates (adjusted for weekends and holidays)). Used for Yield-To-Maturity calculations.


Extended information

Function Syntax

VB Syntax


String CTBonds_y.MoneyMarketBond_y( _
String Key, _
Long Reload, _
CCYEnum Ccy, _
Long SettleDate, _
Long datedDate, _
Long matDate, _
Double coupon, _
DayCountEnum dayCounter, _
String calKey, _
BDCEnum BusDayConv, _
Double redemption, _
Double BondYield, _
FreqEnum YieldQuoteFreq, _
String YieldQMethod)


Excel Spreadsheet Syntax


=CT.BOND.MoneyMarketBond_y(
Excel String Cell Key,
Excel Numeric Cell Reload,
Excel String Cell Ccy,
Excel Numeric Cell SettleDate,
Excel Numeric Cell datedDate,
Excel Numeric Cell matDate,
Excel Numeric Cell coupon,
Excel String Cell dayCounter,
Excel String Cell calKey,
Excel String Cell BusDayConv,
Excel Numeric Cell redemption,
Excel Numeric Cell BondYield,
Excel String Cell YieldQuoteFreq,
Excel String Cell YieldQMethod)


C++ Syntax


static std::string MoneyMarketBond_y(
std::string Key,
long Reload,
CCYEnum Ccy,
long SettleDate,
long datedDate,
long matDate,
double coupon,
DayCountEnum dayCounter,
std::string calKey,
BDCEnum BusDayConv,
double redemption,
double BondYield,
FreqEnum YieldQuoteFreq,
std::string YieldQMethod);


DotNET Syntax


System.String CTBonds_ySA.MoneyMarketBond_y(
System.String Key,
System.Int32 Reload,
CTIEnums.CCYEnum Ccy,
System.Int32 SettleDate,
System.Int32 datedDate,
System.Int32 matDate,
System.Double coupon,
CTIEnums.DayCountEnum dayCounter,
System.String calKey,
CTIEnums.BDCEnum BusDayConv,
System.Double redemption,
System.Double BondYield,
CTIEnums.FreqEnum YieldQuoteFreq,
System.String YieldQMethod);

Parameter data types

ArgNameArgTypeIsKey
KeyStringFALSE
ReloadLongFALSE
CcyCCYEnumFALSE
SettleDateLongFALSE
datedDateLongFALSE
matDateLongFALSE
couponDoubleFALSE
dayCounterDayCountEnumFALSE
calKeyStringTRUE
BusDayConvBDCEnumFALSE
redemptionDoubleFALSE
BondYieldDoubleFALSE
YieldQuoteFreqFreqEnumFALSE
YieldQMethodStringFALSE


Example Inputs

The first column represents the name of the parameters. The second column specifies whether the parameters are optional or not. Finally the last column provides some sample input data.
Function call input string-keys are always in the format : "NAME.EXTTAG.TICKER" The "EXTTAG.TICKER" part is determined from the output of other, capetools, object creation functions.


ArgNameIsOptional (Excel only)Example
KeyFALSEMyMoneyMKTCouponBond_y
ReloadFALSE1
CcyFALSEEUR
SettleDateFALSE19/Jul/2005 (serial date type)
datedDateFALSE21/Apr/2005 (serial date type)
matDateFALSE21/Jul/2007 (serial date type)
couponFALSE0.05
dayCounterFALSEACT365F
calKeyFALSEcalKeyNAME.EXTTAG.TICKER (from a function call)
BusDayConvFALSEModifiedFollowing
redemptionFALSE100
BondYieldFALSE0.055
YieldQuoteFreqFALSEA
YieldQMethodFALSEISMA


Example function usage


The C# example below contains all the sub-function calls leading up to this function call. As a result, the example can contain a lot of code.

The VB.NET, J#, C++.NET, Java, Excel VBA, Visual Basic 6 (via COM) and C++ examples below contain function code stubs for the calls leading up to this function call. However, the function call for this function is displayed.
You can easily reproduce the stub functions code from the C# example.


If you are accessing this functrion via the MiniXL libraries, this function is present within the CT.QL.Bonds20 MiniXL Excel Addin.

Within our Excel Example Addin Generator, we have used the following QuantTools sub-functions in order to prepare the arguments needed to call the MoneyMarketBond_y() function. If you are executing this function via the MiniXL libraries, the module addin name, (in brackets, to the right of the sub-functions listed below), indicates the MiniXL library in which the sub-function is held. You will need to load this library into your Excel session (along with any other libraries that the sub-function call within the addin requires (ie - CT.QT.Utils20 addin in almost all cases) in order for the example to compute successfully.

These are the financial QuantTools sub-function calls that are used within the examples :





The objects generated by these sub-functions are inter-connected in the following way :




The following four examples demostrate calling this function within a Microsoft .NET environment

The following four examples demostrate calling this function within a non .NET environment

The following is a sample output from executing the MoneyMarketBond_y() function call


MyMoneyMKTCouponBond_y_6.MMBND_Y.0

Copyright (c) 2003-2007 CapeTools - All Rights Reserved.