longTermMean | R Documentation |
Long-term means of a calendar
longTermMean(calendar, frequency, groups = c(1, 2, 3, 4, 5, 6, 0), holiday = 7)
calendar |
The calendar. |
frequency |
Annual frequency (divisor of 12). |
groups |
Groups of days. The length of the array must be 7. It indicates to what group each week day belongs. The first item corresponds to Mondays and the last one to Sundays. The group used for contrasts (usually Sundays) is identified by 0. The other groups are identified by 1, 2,... n (<= 6). For instance, usual trading days are defined by c(1,2,3,4,5,6,0), week days by c(1,1,1,1,1,0,0), week days, Saturdays, Sundays by c(1,1,1,1,1,2,0) etc... |
holiday |
Day for holidays (holidays are considered as that day). 1 for Monday... 7 for Sunday. Doesn't necessary belong to the 0-group. |
The long term means corresponding to each group/period, starting with the 0-group.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.