Type: | Package |
Title: | Maps of the Political and Administrative Divisions of Canada |
Version: | 0.1 |
URL: | https://github.com/pachadotdev/canadamaps/ |
BugReports: | https://github.com/pachadotdev/canadamaps/issues |
Description: | Terrestrial maps with simplified topologies for Census Divisions, Agricultural Regions, Economic Regions, Federal Electoral Divisions and Provinces. |
License: | Apache License (≥ 2) |
Encoding: | UTF-8 |
LazyData: | true |
Depends: | R(≥ 3.5.0), sf |
Imports: | rmapshaper, dplyr, magrittr, rlang |
Suggests: | knitr, rmarkdown, ggplot2, testthat |
RoxygenNote: | 7.1.2 |
NeedsCompilation: | no |
Packaged: | 2021-11-29 03:16:23 UTC; pacha |
Author: | Mauricio Vargas Sepulveda [aut, cre], Statistics Canada [dtc] |
Maintainer: | Mauricio Vargas Sepulveda <mv.sepulveda@mail.utoronto.ca> |
Repository: | CRAN |
Date/Publication: | 2021-11-29 20:10:07 UTC |
Pipe operator
Description
See magrittr::%>%
for details.
Usage
lhs %>% rhs
Arguments
lhs |
A value or the magrittr placeholder. |
rhs |
A function call using the magrittr semantics. |
Value
The result of calling 'rhs(lhs)'.
census_divisions
Description
Geometries for each Census Division (CD)
Usage
census_divisions
Format
A data frame
with 293 observations and 6 variables.
Variables
-
cduid
: Census division number. -
cdname
: Census division name. -
cdname
: Census division type (i.e. see the README in the GitHub repository). -
pruid
: Province number. -
prname
: Province name. -
geometry
: Census division shape.
Source
Adapted from official Canadian Census shapefiles.
federal_electoral_districts
Description
Geometries for each Federal Electoral District (FED)
Usage
federal_electoral_districts
Format
A data frame
with 338 observations and 5 variables.
Variables
-
feduid
: Census division number. -
fedname
: Federal electoral district name. -
pruid
: Province number. -
prname
: Province name. -
geometry
: Federal electoral district shape.
Source
Adapted from official Canadian Census shapefiles.
Canadian Map at Census Agricultural Region (CAR) Level
Description
This function aggregates the Census Divisions (CD) map to provide the Census Agricultural Region (CAR) map. The idea is to avoid providing a dataset with map that can be obtained as an aggregation of another.
Usage
get_agricultural_divisions(map = census_divisions)
Arguments
map |
which map to add, by default it takes the complete Census Divisions (CD) map |
Value
a tibble with economic regions, provinces and geometry (multipolygon) fields.
Examples
get_agricultural_divisions(
census_divisions[census_divisions$prname == "Ontario",]
)
Canadian Map at Economic Region (ER) Level
Description
This function aggregates the Census Divisions (CD) map to provide the Economic Region (ER) map. The idea is to avoid providing a dataset with map that can be obtained as an aggregation of another.
Usage
get_economic_regions(map = census_divisions)
Arguments
map |
which map to add, by default it takes the complete Census Divisions (CD) map |
Value
a tibble with economic regions, provinces and geometry (multipolygon) fields.
Examples
get_economic_regions(
census_divisions[census_divisions$prname == "Ontario",]
)
Canadian Map at Province (ER) Level
Description
This function aggregates the Census Divisions (CD) map to provide the Province map. The idea is to avoid providing a dataset with map that can be obtained as an aggregation of another.
Usage
get_provinces(map = census_divisions)
Arguments
map |
which map to add, by default it takes the complete Census Divisions (CD) map |
Value
a tibble with provinces and geometry (multipolygon) fields.
Examples
get_provinces(
census_divisions[census_divisions$prname == "Ontario",]
)