seasdummy: Create seasonal dummy variables.
Description
Create binary or trigonometric seasonal dummies.
Usage
seasdummy(n, m = NULL, y = NULL, type = c("bin", "trg"),
full = c(FALSE, TRUE))
Arguments
n
number of observations to create.
m
seasonal periodicity. If NULL
it will take the information from the provided time series (y
argument). See notes.
y
this is an optional time series input that can be used to get seasonal periodicity (m
) and the start point.
type
type of seasonal dummies to create.
full
If full is TRUE
, then keeps the m-th dummy that is co-linear to the rest. See notes.
Value
An array with seasonal dummies, where rows correspond observations and columns to dummy variables.
Examples
Run this code# NOT RUN {
seasdummy(24,12)
# }
Run the code above in your browser using DataLab