You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Merging dev into master. Will update to CRAN later this week. I'm thinking we roll this out now with the changes to make 1996 work seamlessly and worry about the rest later. Not sure yet how we want to surface the geometry intersection capabilities - let's leave that for 0.3.3.
Copy file name to clipboardExpand all lines: R/cancensus.R
+13-29Lines changed: 13 additions & 29 deletions
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@
9
9
#'
10
10
#' @param dataset A CensusMapper dataset identifier.
11
11
#' @param regions A named list of census regions to retrieve. Names must be valid census aggregation levels.
12
-
#' @param level The census aggregation level to retrieve, defaults to \code{"Regions"}. One of \code{"Regions"}, \code{"PR"}, \code{"CMA"}, \code{"CD"}, \code{"CSD"}, \code{"CT"}or \code{"DA"}.
12
+
#' @param level The census aggregation level to retrieve, defaults to \code{"Regions"}. One of \code{"Regions"}, \code{"PR"}, \code{"CMA"}, \code{"CD"}, \code{"CSD"}, \code{"CT"}, \code{"DA"}, \code{"EA"} (for 1996), or \code{"DB"} (for 2001-2016).
13
13
#' @param vectors An R vector containing the CensusMapper variable names of the census variables to download. If no vectors are specified only geographic data will get downloaded.
14
14
#' @param geo_format By default is set to \code{NA} and appends no geographic information. To include geographic information with census data, specify one of either \code{"sf"} to return an \code{\link[sf]{sf}} object (requires the \code{sf} package) or \code{"sp"} to return a \code{\link[sp]{SpatialPolygonsDataFrame-class}} object (requires the \code{rgdal} package).
15
15
#' @param labels Set to "detailed" by default, but truncated Census variable names can be selected by setting labels = "short". Use \code{label_vectors(...)} to return variable label information in detail.
@@ -54,11 +54,11 @@ get_census <- function (dataset, regions, level=NA, vectors=c(), geo_format = NA
54
54
55
55
# Turn the region list into a valid JSON dictionary.
56
56
if (is.character(regions)) {
57
-
if (!quiet) warning(paste("passing `regions` as a character vector is",
57
+
if (!quiet) warning(paste("Passing `regions` as a character vector is",
Copy file name to clipboardExpand all lines: README.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,8 +12,8 @@ Access, retrieve, and work with Canadian Census data and geography.
12
12
* Download data and Census geography in tidy and analysis-ready format
13
13
* Convenience tools for searching for and working with Census regions and variable hierarchies
14
14
* Provides Census geography in multiple R spatial formats
15
-
* Provides data and geography at multiple Census geographic levels including province, Census Metropolitan Area, Census Division, Census Subdivision, Census Tract, and Dissemination Areas
16
-
* Provides data for the 2016, 2011, 2006, and 2001 Census releases
15
+
* Provides data and geography at multiple Census geographic levels including province, Census Metropolitan Area, Census Division, Census Subdivision, Census Tract, Dissemination Areas, Enumeration Areas (for 1996), and Dissemination Blocks (for 2001-2016)
16
+
* Provides data for the 2016, 2011, 2006, 2001, and 1996 Census releases
17
17
* Access to taxfiler data at the Census Tract level for tax years 2000 through 2017
18
18
19
19
### Reference
@@ -35,7 +35,7 @@ library(cancensus)
35
35
36
36
### API key
37
37
38
-
This package relies on queries to the CensusMapper API, which requires a Censusmapper API key. You can obtain a free API key by [signing up](https://censusmapper.ca/users/sign_up) for a CensusMapper account. CensusMapper API keys are free; however, API requests are limited in volume. For larger quotas, please get in touch with Jens [directly](mailto:jens@censusmapper.ca).
38
+
**cancensus** requires a valid CensusMapper API key to use. You can obtain a free API key by [signing up](https://censusmapper.ca/users/sign_up) for a CensusMapper account. CensusMapper API keys are free and public API quotas are generous; however, due to incremental costs of serving large quantities of data, there limits to API usage in place. For most use cases, these API limits should not be an issue. Production uses with large extracts of fine grained geographies may run into API quota limits. For larger quotas, please get in touch with Jens [directly](mailto:jens@censusmapper.ca).
39
39
40
40
To check your API key, just go to "Edit Profile" (in the top-right of the CensusMapper menu bar). Once you have your key, you can store it in your system environment so it is automatically used in API calls. To do so just enter `options(cancensus.api_key = "your_api_key")`.
41
41
@@ -45,7 +45,7 @@ For performance reasons, and to avoid unnecessarily drawing down API quotas, **c
45
45
46
46
### Currently available datasets
47
47
48
-
**cancensus** can access Statistics Canada Census data for the 2001 Census, the 2006 Census, the 2011 Census and National Household Survey, as well as the 2016 Census. You can run `list_census_datasets` to check what datasets are currently available for access through the CensusMapper API. Additional data for the 2016 Census will be included in Censusmapper within a day or two after public release by Statistics Canada. Statistics Canada maintains a release schedule for the Census 2016 Program which can be viewed on their [website](http://www12.statcan.gc.ca/census-recensement/2016/ref/release-dates-diffusion-eng.cfm).
48
+
**cancensus** can access Statistics Canada Census data for Census years 1996, 2001, 2006, 2011, and 2016. You can run `list_census_datasets` to check what datasets are currently available for access through the CensusMapper API. Additional data for the 2016 Census will be included in Censusmapper within a day or two after public release by Statistics Canada. Statistics Canada maintains a release schedule for the Census 2016 Program which can be viewed on their [website](http://www12.statcan.gc.ca/census-recensement/2016/ref/release-dates-diffusion-eng.cfm).
49
49
50
50
Thanks to contributions by the Canada Mortgage and Housing Corporation (CMHC), **cancensus** now includes additional Census-linked datasets as open-data releases. These include annual taxfiler data at the census tract level for tax years 2000 through 2017, which includes data on incomes and demographics, as well as specialized crosstabs for Structural type of dwelling by Document type, which details occupancy status for residences. These crosstabs are available for the 2001, 2006, 2011, and 2016 Census years at all levels starting with census tract.
51
51
@@ -107,7 +107,7 @@ We'd love to feature examples of work or projects that use cancensus.
107
107
If you wish to cite cancensus:
108
108
109
109
von Bergmann, J., Aaron Jacobs, Dmitry Shkolnik (2020). cancensus: R package to
110
-
access, retrieve, and work with Canadian Census data and geography. v0.3.1.
110
+
access, retrieve, and work with Canadian Census data and geography. v0.3.2.
111
111
112
112
113
113
A BibTeX entry for LaTeX users is
@@ -116,7 +116,7 @@ A BibTeX entry for LaTeX users is
116
116
author = {Jens {von Bergmann} and Dmitry Shkolnik and Aaron Jacobs},
117
117
title = {cancensus: R package to access, retrieve, and work With Canadian Census data and geography},
0 commit comments