e= exceltime(t)返回一个doublearray containing Excel®serial date numbers equivalent to the datetime values int. Excel serial date numbers are the number of days and fractional days since 0-January-1900 00:00:00, and do not take into account time zone and leap seconds.
e= exceltime(t,dateType)returns the type of Excel serial date numbers specified bydateType. For example, you can convert datetime values to the number of days since 1-January-1904 00:00:00.
dateType—Type of Excel serial date numbers '1900'(default) |'1904'
Type of Excel serial date numbers, specified as either'1900'or'1904'.
IfdateTypeis'1900', thenexceltimeconverts the datetime values intto the equivalent the number of days and fractional days since 0-January-1900 00:00:00.
IfdateTypeis'1904', thenexceltimeconverts the datetime values intto the equivalent the number of days and fractional days since 1-January-1904 00:00:00.
e— Excel serial date numbers scalar | vector | matrix | multidimensional array
Excel serial date numbers, returned as a scalar, vector, matrix, or multidimensional array of typedouble. Excel serial date numbers are not defined prior to their epoch (0-January-1900 or 1-January-1904). Excel serial date numbers treat 1900 as a leap year. Therefore, dates after February 28, 1900 are offset by one day relative to MATLAB®serial date numbers, and there is a discontinuity of one day between February 28, 1900 and March 1, 1900.
Extended Capabilities
Tall Arrays Calculate with arrays that have more rows than fit in memory.
This function fully supports tall arrays. For more information, seeTall Arrays.
Distributed Arrays Partition large arrays across the combined memory of your cluster using Parallel Computing Toolbox™.
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.