mkmonths(Y;M)

Make a months (interval) value from years and months. (Available as of version 20.04)

Syntax

mkmonths(Y;M)

Input

Argument Type Description
Y integer A scalar value or the name of a column containing an integer, representing the years.
M integer A scalar value or the name of a column containing an integer, representing the months.

Either value may be omitted or NA, in which case it will default to 0. If no non-NA values are provided, the return value will be NA.

Return Value

Returns an integer value, the number of months in the interval (12×Y+M).

For more information about date formats, see Dates and time.

If the input values are not in one of the supported formats listed above, the function returns an erroneous or illogical output.