Description Usage Arguments Functions Examples
Given a date, it returns the number of days in the month.
1 2 3 4 5 6 7 | NumDaysInMonth(date)
MonthName(month.idx, short = FALSE)
NumHoursInMonth(Date, market = "PNW")
DiffMonths(dates, date1)
|
date |
Date in either 'character' or 'date' format. |
month.idx |
An integer (1:12) indicating month index. |
short |
A binary. If TRUE, month names are shown in abbreviated forms. |
market |
"PNW", "CAISO" or "MISO" |
MonthName
: Given month index, returns the month name.
NumHoursInMonth
: Given series of date (first days of month), it returns a data frame containing number of peak and off-peak hours.
DiffMonths
: Given 2 dates, it returns the number of months in between. The first argument can be a vector.
1 2 3 4 5 | dates <- seq(as.Date("2000-1-1"), length.out = 6, by="mon")
NumDaysInMonth(dates)
MonthName(MonthFromDate(dates))
NumHoursInMonth(dates)
DiffMonths(dates, as.Date("2000-3-1"))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.