Purpose
Return value
Syntax
=NPV(rate,value1,[value2],...)
- rate - Discount rate over one period.
- value1 - First value(s) representing cash flows.
- value2 - [optional] Second value(s) representing cash flows.
Using the NPV function
NPV calculates the net present value (NPV) of an investment using a discount rate and a series of future cash flows. The discount rate is the rate for one period, assumed to be annual. NPV in Excel is a bit tricky, because of how the function is implemented. Although NPV carries the idea of “net”, as in the present value of future cash flows less initial cost, NPV is really just the present value of uneven cash flows.
As Timothy R. Mayes, author of Financial Analysis with Microsoft Excel , says on his website TVMCalcs.com :
Net present value is defined as the present value of the expected future cash flows less the initial cost of the investment…the NPV function in spreadsheets doesn’t really calculate NPV. Instead, despite the word “net,” the NPV function is really just a present value of an uneven cash flow function.
One simple approach is to exclude the initial investment from the values argument and instead subtract the amount outside the NPV function.
In the example shown, the formula in F6 is:
=NPV(F4,C6:C10)+C5
Note the initial investment in C5 is not included as a value, and is instead added to the result of NPV (since the number is negative).
Notes
- values must be equally spaced in time and occur at the end of each period.
- values must be in chronological order.
Purpose
Return value
Syntax
=ODDFPRICE(sd,md,id,fd,rate,yld,redem,freq,[basis])
- sd - Settlement date of the security.
- md - Maturity date of the security.
- id - Issue date of the security.
- fd - First coupon date.
- rate - Annual coupon rate of security.
- yld - Annual required rate of return.
- redem - Redemption value per $100 face value.
- freq - Coupon payments per year (annual = 1, semiannual = 2; quarterly = 4).
- basis - [optional] Day count basis (see below, default =0).
Using the ODDFPRICE function
Some bonds have an irregular first or last period, so interest payments don’t fit a normal schedule. To calculate the price of a bond with an irregular first period, you can use the ODDFPRICE function. The ODDFPRICE Function returns the price per $100 face value of a security having an irregular (short or long) first period.
Example
Assume we need to calculate the price per $100 face value of a bond with a first coupon date of 15-Feb-2019. The bond was issued on 1-Dec-2018, matures on 15-Feb-2022, and pays a coupon rate of 5% with a required return of 6%. Payments are semi-annual, the day count basis is US 30/360, and the redemption value is $100. In the example shown, the formula in F5 is:
=ODDFPRICE(C9,C11,C8,C10,C6,C7,C5,C12,C13)
With these inputs, the ODDFPRICE function returns 97.26, with currency number format applied.
Entering dates
In Excel, dates are serial numbers . Generally, the best way to enter valid dates is to use cell references, as shown in the example. To enter valid dates directly inside a function, you can use the DATE function . To illustrate, the formula below has all values hardcoded. The DATE function is used to supply each of the four required dates:
=ODDFPRICE(DATE(2019,2,1),DATE(2022,2,15),DATE(2018,12,1),DATE(2019,2,15),0.05,0.06,100,2,0)
Basis
The basis argument controls how days are counted. The ODDFPRICE function allows 5 options (0-4) and defaults to zero, which specifies US 30/360 basis . This article on Wikipedia provides a detailed explanation of available conventions.
| Basis | Day count |
|---|---|
| 0 or omitted | US (NASD) 30/360 |
| 1 | Actual/actual |
| 2 | Actual/360 |
| 3 | Actual/365 |
| 4 | European 30/360 |
Notes
- In Excel, dates are serial numbers .
- All dates, plus frequency and basis , are truncated to integers.
- If dates are invalid (i.e. not actually dates) ODDFPRICE returns #VALUE!
- ODDFPRICE returns #NUM when: ( maturity > first_coupon > settlement > issue ) is not true Maturity does not follow frequency interval w.r.t last coupon date Basis is out-of-range