| Financial Toolbox | Search  Help Desk |
| days360 | Examples See Also |
Days between dates based on 360-day year.
Syntax
nd = days360(d1, d2) nd = days360(d1, d2, eom)
Description
nd = days360(d1, d2)
returns the number of days nd between dates d1 and d2 based on a 360-day year. If d2 is earlier than d1, nd is negative. Enter dates as serial date numbers or date strings.
Either input argument can contain multiple values, but if so, the other input must contain the same number of values or a single value that applies to all. For example, if d1 is an N-row character array of date strings, then d2 must be an N-row character array of date strings or a single date. nd is then an N-by-1 vector of numbers.
Note: The eom argument now has no effect. The argument was mistakenly included in the previous release due to a misinterpretation of SIA guidelines. (The end-of-month rule applies only to the fixing of coupon dates for bonds with a 30/360 basis, not to the actual measurement of days between two dates on a 30/360 basis.) The eom argument is still allowed to provide compatibility for applications that use it, but it will be removed in a future release.
Examples
nd = days360('15-jan-1997', '15-mar-1997')
nd =
60
d2 = ['15-mar-1997'; '15-apr-1997'; '15-jun-1997'];
nd = days360('15-jan-1997', d2)
nd =
60
90
150
See Also
days365, daysact, daysdif, wrkdydif, yearfrac
Reference
Addendum to Securities Industry Association, Standard Securities Calculation Methods: Fixed Income Securities Formulas for Analytic Measures, Vol. 2, Spring 1995.