Learn R Programming

IceCast (version 2.1.0)

get_init_month: Get initialization month

Description

Determine initialization month based on month being forecast and lag. Considers lags up to 11 months in advance.

Usage

get_init_month(month, lag)

Arguments

month

forecast month (integer from 1 to 12 corresponing to month of year)

lag

months in advance prediction is being made (integer from 1 to 11).

Value

integer corresponding to the initialization month

Details

Note that this calculation assumes that the prediction for a month is its on first day. This differs from the labeling used in Director et al. (2017) which rounds up to the nearest full month.

Examples

Run this code
# NOT RUN {
init_month <- get_init_month(month = 10, lag = 4)
init_month
# }

Run the code above in your browser using DataLab