| Financial Toolbox | ![]() |
Syntax
Busday = busdate(Date, Direction, Holiday)
Date |
Reference date. Enter as serial date number or date string. |
Direction |
(Optional) Direction. 1 = next (default) or -1 = previous business day. |
Holiday |
(Optional) Vector of holidays and nontrading-day dates. All dates in Holiday must be the same format: either serial date numbers or date strings. (Using serial date numbers improves performance.) The holidays function supplies the default vector. |
Description
Busday = busdate(Date, Direction, Holiday)
returns the serial date number of the next or previous business day from the reference date.
datestr to convert serial date numbers to formatted date strings.
Examples
Busday = busdate('3-Jul-2001', 1, holidays)
Busday =
731037
datestr(Busday)
ans =
05-Jul-2001
| bolling | candle | ![]() |