calendar | R Documentation |
The calendar API serves the full list of market days from 1970 to 2029. It can also be queried by specifying a start and/or end time to narrow down the results. In addition to the dates, the response also contains the specific open and close times for the market days, taking into account early closures. See Calendar Endpoint for details.
calendar(from = NULL, to = NULL)
from |
|
to |
|
Calendar tibble
A Calendar Object consisting of the following:
date
(character)
vector of trading days in the time range
open
(character)
The time the market opens at on this date in hour:min format as a string.
close
(character)
The time the market closes at on this date in hour:min format as a string.
session_open
(character)
The start time of the session in hh:mm format
session_close
(character)
The closing time of the session in hh:mm format.
day
(Interval)
An interval of the market day open %--% close
.
session
(Interval)
An interval of the market session session_open %--% session_close
.
dow
(character)
Three letter abbreviation of the day of the week as an ordered factor with levels Sunday - Saturday.
Interval-class
## Not run:
# Get all dates:
calendar()
# Get specific date range:
calendar(from = "2019-01-01", to = "2019-04-01")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.