Main Content
year
Year number of input date and time
Description
y = year(
returns the year number
for each date and time in the input array. By default, t
)year
returns ISO year numbers, which include a year zero and represent years BCE
using negative values.
The output y
is a double
array. To
assign ISO year values to a datetime
array,
t
, use t.Year
and modify the Year
property.