find_observedday: Find observed holiday over weekends

View source: R/utils.R

find_observeddayR Documentation

Find observed holiday over weekends

Description

When a holiday lands on Saturday or Sunday, they are typically observed the following Monday. Boxing day is an exception and will occur on Tuesday if Dec-26 occurs on a Monday.

Usage

find_observedday(year, month, day)

Arguments

year

character or numeric for 4 digit year.

month

character or numeric (01-12) for month of which holiday of interest occurs.

day

character or numeric (01-31) for day of which holiday of interest occurs.

Value

Date object in YYYY-MM-DD format.

Examples

find_observedday(2021, month = 12, day = 25)
lapply(c(1990:2000), find_observedday, month = 12, day = 25)

al-obrien/farrago documentation built on April 14, 2023, 6:20 p.m.