The statcan_search()
function has 2 arguments to fulfill to find a database: keywords and lang.
The keywords argument refers to words that can be found in either the title or the description of the database. For example, inserting the keywords
"economy","export",and "link" will bring up the title, table id, description, and release date for databases that include these keywords. In this case, only one data table ("Supply and use tables, link-1997 level")
would be returned as it is the only data table containing all three words.
statcan_search(keywords, lang)
The words that appear in the title or description of the data table
The language wanted
The output will be the title, id, description, and release date of a table
Easily connect to Statistics Canada's Web Data Service with R. Open economic data (formerly known as CANSIM tables, now identified by Product IDs (PID)) are accessible as a data frame, directly in the user's R environment.
statcan_search(c("economy","export","link"),"eng")