statcan
Statistics Canada tools: search tables, retrieve metadata, fetch time series data, and monitor data changes.
lang: "en" | "fr". Open each tool below for its source-derived parameters.sc_search_cubes
Search Statistics Canada tables (cubes) by keyword using BM25 ranking.
Use forfinding relevant Statistics Canada data tables when you know a
statcan, statistics canada, table, cube, search, find, catalog, browse, dataset, survey, subject, BM25, keyword, lookup
| Parameter | Type | Default |
|---|---|---|
query | str | required |
limit | int | 10 |
lang | Literal['en', 'fr'] | 'en' |
sc_get_cube_metadata
Get full metadata and dimension structure for a Statistics Canada table.
Use forretrieving table title, frequency, date range, and all dimension
statcan, statistics canada, table, metadata, dimensions, product id, cube, structure, frequency, geography, members, schema
| Parameter | Type | Default |
|---|---|---|
product_id | int | required |
lang | Literal['en', 'fr'] | 'en' |
sc_get_code_sets
Get all WDS code sets for decoding numeric codes in StatCan responses.
Use fordecoding frequencyCode, scalarFactorCode, statusCode, symbolCode,
statcan, statistics canada, code sets, frequency, scalar, status, symbol, uom, decode, legend, reference, lookup
| Parameter | Type | Default |
|---|---|---|
lang | Literal['en', 'fr'] | 'en' |
sc_get_series_info_by_vector
Get series metadata by vectorId (title, frequency, scalar factor, units).
Use forlooking up series title, frequency, and scalar factor when you
statcan, statistics canada, series, vector, metadata, vectorId, frequency, scalar, units, title, time series, info
| Parameter | Type | Default |
|---|---|---|
vector_id | int | required |
lang | Literal['en', 'fr'] | 'en' |
sc_get_series_info_by_coord
Get series metadata by productId + coordinate (dot-separated dimension members).
Use forlooking up a series when you know the table (productId) and the
statcan, statistics canada, series, coordinate, product id, table, dimension, members, metadata, frequency, scalar, time series
| Parameter | Type | Default |
|---|---|---|
product_id | int | required |
coordinate | str | required |
lang | Literal['en', 'fr'] | 'en' |
sc_get_data_by_vector
Get the latest N observations for a Statistics Canada series by vectorId.
Use forfetching recent data points for a known series (vectorId). Returns
statcan, statistics canada, observations, data, vector, vectorId, latest, recent, time series, values, historical, n periods
| Parameter | Type | Default |
|---|---|---|
vector_id | int | required |
n | int | 10 |
lang | Literal['en', 'fr'] | 'en' |
sc_get_data_by_coord
Get the latest N observations for a Statistics Canada series by productId + coordinate.
Use forfetching recent data points when you know the table (productId)
statcan, statistics canada, observations, data, coordinate, product id, dimension, latest, recent, time series, n periods, values
| Parameter | Type | Default |
|---|---|---|
product_id | int | required |
coordinate | str | required |
n | int | 10 |
lang | Literal['en', 'fr'] | 'en' |
sc_get_data_by_date_range
Get Statistics Canada observations within a reference period date range.
Use forfetching all data points between two reference period dates for a
statcan, statistics canada, observations, date range, reference period, vector, time series, historical, start date, end date, range, filter
| Parameter | Type | Default |
|---|---|---|
vector_id | int | required |
start_date | str | required |
end_date | str | required |
lang | Literal['en', 'fr'] | 'en' |
sc_get_bulk_vector_data
Get observations for multiple Statistics Canada series within a release date range.
Use forefficiently fetching data for many series at once when you care
statcan, statistics canada, bulk, multiple, vectors, release date, observations, batch, parallel, time series, data, efficient
| Parameter | Type | Default |
|---|---|---|
vector_ids | list[int] | required |
start_release | str | required |
end_release | str | required |
lang | Literal['en', 'fr'] | 'en' |
sc_get_changed_series
Get the list of Statistics Canada series (vectors) that changed today.
Use formonitoring which series were updated in today's release cycle.
statcan, statistics canada, changed, updated, series, vectors, today, monitoring, release, daily, changes, refresh
| Parameter | Type | Default |
|---|---|---|
lang | Literal['en', 'fr'] | 'en' |
sc_get_changed_cubes
Get the list of Statistics Canada tables (cubes) that changed on a specific date.
Use forfinding which tables were updated on a given date (YYYY-MM-DD).
statcan, statistics canada, changed, updated, cubes, tables, date, monitoring, release, history, changes, refresh
| Parameter | Type | Default |
|---|---|---|
date | str | required |
lang | Literal['en', 'fr'] | 'en' |
sc_get_sdmx_structure
Get SDMX dimension codelists for a Statistics Canada table.
Use forfetching dimension codelists for a StatCan table before building
SDMX, structure, codelist, dimension, filter, server-side, statcan, table, metadata, key, codes, schema
| Parameter | Type | Default |
|---|---|---|
product_id | int | required |
lang | Literal['en', 'fr'] | 'en' |
sc_get_sdmx_data
Get server-side filtered StatCan observations using SDMX key syntax.
Use forretrieving server-side filtered StatCan observations using SDMX
SDMX, data, filter, observations, key, server-side, statcan, dimension, date range, lastN, period, time series
| Parameter | Type | Default |
|---|---|---|
product_id | int | required |
key | str | '' |
start_period | str | None | None |
end_period | str | None | None |
last_n | int | None | None |
dimensions | dict | None | None |
lang | Literal['en', 'fr'] | 'en' |
sc_get_sdmx_vector_data
Get observations for a single StatCan vector via SDMX with date range filtering.
Use forretrieving observations for a single StatCan vector via SDMX with
SDMX, vector, observations, date range, time series, statcan, vectorId, filter, period, single series, SDMX-JSON
| Parameter | Type | Default |
|---|---|---|
vector_id | int | required |
start_period | str | None | None |
end_period | str | None | None |
lang | Literal['en', 'fr'] | 'en' |
sc_fetch_vectors_to_store
Fetch multiple StatCan vectors and store them to the shared datastore for SQL queries.
Use forfetching multiple StatCan vectors and storing them directly to the
composite, store, fetch, vectors, datastore, SQL, statcan, bridge, persist, table, bulk, cross-module
| Parameter | Type | Default |
|---|---|---|
vector_ids | list[int] | required |
start_release | str | required |
end_release | str | required |
table_name | str | required |
lang | Literal['en', 'fr'] | 'en' |