| Financial Toolbox™ | ![]() |
newfts = todaily(oldfts) newfts = todaily(oldfts, ParameterName, ParameterValue, ...)
oldfts | Financial time series object |
newfts = todaily(oldfts) converts a financial time series of any frequency to a daily frequency.
Note If oldfts contains time-of-day information, newfts displays the time-of-day as '00:00' for those days that did not previously exist in oldfts. Empty ([ ]) passed as inputs for parameter pair values for todaily will trigger the use of the defaults. |
newfts = todaily(oldfts, ParameterName, ParameterValue, ...) accepts parameter name/parameter value pairs as input, as specified in the following table.
Parameter Name | Parameter Value | Description |
|---|---|---|
CalcMethod | Exact | Returns the value located at specific dates/times. No data manipulation occurs. |
v21x | This mode is compatible with previous versions of this function (Version 2.1.x and earlier). It returns a five-day business week that starts on Monday and ends on Friday. | |
BusDays | 0 | Generates a financial time series that ranges from (or between) the first date to the last date in oldfts (includes NYSE nonbusiness days and holidays). |
1 | (Default) Generates a monthly financial time series that ranges from the first date to the last date in oldfts (excludes NYSE nonbusiness days and holidays and weekends based on AltHolidays and Weekend). If an end-of-month date falls on a nonbusiness day or NYSE holiday, returns the last business day of the month. NYSE market closures, holidays, and weekends are observed if AltHolidays and Weekend are not supplied or empty ([]). | |
DateFilter | Absolute | (Default) Displays all daily dates between the start and end dates of oldfts. Some dates may be disregarded if BusDays = 1. |
Relative | Displays only dates that exist in oldfts. Some dates may be disregarded if BusDays = 1. | |
TimeSpec | First | Returns only the observation that occurs at the first (earliest) time for a specific date. |
Last | (Default) Returns only the observation that occurs at the last (latest) time for a specific date. | |
AltHolidays | Vector of dates specifying an alternate set of market closure dates. | |
-1 | Excludes all holidays. | |
Weekend | Vector of length 7 containing 0's and 1's. The value 1 indicates a weekend day. The first element of this vector corresponds to Sunday. For example, when Saturday and Sunday are weekend days (default) then Weekend = [1 0 0 0 0 0 1]. | |
convertto, toannual, tomonthly, toquarterly, tosemi, toweekly
![]() | toannual | today | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |