isdatetime - Determine if input is datetime array - MATLAB (original) (raw)
Main Content
Determine if input is datetime array
Syntax
Description
tf = isdatetime([t](#buep30u-1-t))
returns logical 1
(true
) if t
is a datetime array. Otherwise, it returns logical 0
(false
).
Examples
Define an array.
A = [datetime('now');datetime('tomorrow');datetime(2016,1,15)]
A = 3×1 datetime 01-Feb-2025 09:01:55 02-Feb-2025 00:00:00 15-Jan-2016 00:00:00
Determine if the array is a datetime
array.
Input Arguments
Input array, specified as a scalar, vector, matrix, or multidimensional array. t
can be any data type.
Extended Capabilities
Version History
Introduced in R2014b