cso_get_toc | R Documentation |
Checks the CSO PxStat API for a list of all the table codes (e.g. A0101, A0102, A0103, etc.), which also includes date last modified and title for each table, and returns this list as an R data frame.
cso_get_toc(
cache = FALSE,
suppress_messages = FALSE,
get_frequency = FALSE,
list_vars = FALSE,
flush_cache = TRUE,
from_date = "YYYY-MM-DD"
)
cache |
logical. If TRUE the table of contents is cached with the system date as a key. |
suppress_messages |
logical. If FALSE (default) a message is printed when loading a previously cached table of contents. |
get_frequency |
logical. If TRUE the frequency of each table(yearly, monthly etc...) will be returned as an additional column in the table of contents. |
list_vars |
logical. If TRUE an additional column will be added to the table of contents which lists each tables variables. |
flush_cache |
logical. If TRUE (default) the cache will be checked for old, unused files. Any files which have not been accessed in the last month will be deleted. |
from_date |
date in the format YYYY-MM-DD or Null. Will only return tables last modified after date provided. Default is 2 years from current date. |
The data is pulled from the ReadCollection on the CSO API. See https://github.com/CSOIreland/PxStat/wiki/API-Cube-RESTful for more information on this.
data frame of three character columns:
id. Contains all of the table codes currently available on the CSO API.
LastModified. The date the table was last modified in POSIXct format.
title. The title of the table.
## Not run:
head(cso_get_toc())
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.