d = seconds(x)
x = seconds(d)
| Parameter | Description |
|---|---|
| inputs | Numeric second counts or duration arrays. |
| Parameter | Description |
|---|---|
| output | A duration array for numeric input, or double second counts for duration input. |
Create durations from seconds or extract seconds from durations.
seconds is the base elapsed-time unit used by duration. It is useful for numeric comparisons, arithmetic, and conversion from other duration units.
Array-valued inputs keep their data shape when the operation supports arrays. Scalar operands are expanded where the implementation defines scalar expansion.
d = seconds([1 2])
seconds(minutes(2))
| Version | Description |
|---|---|
| 2.0.0 | initial version |