get_year: Get the assessment year

View source: R/get_year.R

get_yearR Documentation

Get the assessment year

Description

Get the assessment year based on the current month. If the current month is past June, then it is more than likely that you are working on an assessment for next year and thus the assessment year would be current year + 1.

Usage

get_year(incrementafter = "September")

Arguments

incrementafter

A character or numeric value representing the last month you would be working on an assessment for the current year. The default, "September", leads to the returned value being the next year if the current month is October or later. If using the character version, it must be the full month name, though case is ignored.

Value

An integer object representing the current year.

Author(s)

Kelli Faye Johnson

Examples

# Use an integer to represent the month
get_year(2)
# Use full month name
get_year("February")
# Case does not matter
get_year("may")


iantaylor-NOAA/Lingcod_2021 documentation built on Oct. 30, 2024, 6:42 p.m.