Bond Duration
bond-durationMacaulay duration (PV-weighted average time of cashflows, in years) and modified duration (price sensitivity to yield).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"faceValue": "<faceValue>",
"couponRatePct": "<couponRatePct>",
"years": "<years>",
"yieldPct": "<yieldPct>"
},
"name": "bond-duration"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| years | Yes | Years to maturity. | |
| yieldPct | Yes | Annual yield in percent. | |
| faceValue | Yes | Face value. | |
| couponRatePct | Yes | Annual coupon rate in percent. | |
| periodsPerYear | No | Coupon periods per year (default 2). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| macaulay | No | Macaulay duration, years. | |
| modified | No | Modified duration. |