d = timeofday(t)
| Parameter | Description |
|---|---|
| inputs | A datetime array. |
| Parameter | Description |
|---|---|
| output | A duration array containing the time-of-day component. |
Return the elapsed time since midnight for datetime values.
timeofday discards the calendar date and keeps only the fractional day, expressed as a duration with hh:mm:ss display format.
Array-valued inputs keep their data shape when the operation supports arrays. Scalar operands are expanded where the implementation defines scalar expansion.
d = timeofday(datetime(2024, 1, 1, 12, 30, 0))
seconds(d)
| Version | Description |
|---|---|
| 2.0.0 | initial version |