Constructing and Analyzing Cash Flows Using the Finance Package
|
Overview
|
|
The Financial Modeling package provides a number of tools for constructing cash flows and for performing basic sensitivity analysis. Here is the list of related commands.
|
|
Constructing Cash Flows
|
|
First construct a simple cash flow that pays 100 on the first business day three months from now. Set the global evaluation date to November 17, 2006.
>
|
|
>
|
|
| (2.1) |
>
|
|
| (2.2) |
>
|
|
| (2.3) |
Every cash flow is represented by a module with two exports: amount and date. The first one holds the amount to be paid. The second one holds the payment date.
>
|
|
| (2.4) |
>
|
|
| (2.5) |
>
|
|
| (2.6) |
>
|
|
| (2.7) |
You can calculate the net present value of this cash flow using any given discount rate.
>
|
|
| (2.8) |
This is the value of our cash flow on November 17, 2006, which is the global evaluation date. You can use different dates by using appropriate term structures or by specifying the reference date explicitly.
>
|
|
| (2.9) |
You can also construct cash flows that represent fixed- and floating-rate coupon payments.
>
|
|
| (2.10) |
>
|
|
| (2.11) |
>
|
|
| (2.12) |
>
|
|
| (2.13) |
>
|
|
| (2.14) |
>
|
|
| (2.15) |
Next construct a floating-rate coupon payment.
>
|
|
| (2.16) |
>
|
|
| (2.17) |
>
|
|
| (2.18) |
>
|
|
>
|
|
| (2.19) |
>
|
|
>
|
|
| (2.20) |
>
|
|
| (2.21) |
>
|
|
| (2.22) |
>
|
|
| (2.23) |
>
|
|
| (2.24) |
>
|
|
| (2.25) |
|
|
Performing Sensitivity Analysis
|
|
Consider the set of cash flows defined previously.
>
|
|
| (3.1) |
You can calculate the convexity of our set of cash flows using the 5% and the 4% rate.
>
|
|
| (3.2) |
>
|
|
| (3.3) |
Another sensitivity measure is the basis point sensitivity.
>
|
|
| (3.4) |
>
|
|
| (3.5) |
You can also compute 3 different types of duration at different market prices.
>
|
|
| (3.6) |
You can use the internal rate of return of your set of cash flows to compute the Macaulay duration.
>
|
|
| (3.7) |
>
|
|
| (3.8) |
|
|
Download Help Document
Was this information helpful?