| Title: | Effortlessly Create Stunning Canadian Maps | 
| Version: | 2.0.0 | 
| Description: | Simple and seamless access to a variety of 'StatCan' shapefiles for mapping Canadian provinces, regions, forward sortation areas, census divisions, and subdivisions using the popular 'ggplot2' package. | 
| License: | MIT + file LICENSE | 
| Encoding: | UTF-8 | 
| LazyData: | true | 
| LazyDataCompression: | xz | 
| RoxygenNote: | 7.2.0 | 
| URL: | https://github.com/joellecayen/canadianmaps | 
| BugReports: | https://github.com/joellecayen/canadianmaps/issues | 
| Imports: | ggplot2, sp, sf, ggrepel, RColorBrewer, dplyr | 
| Depends: | R (≥ 2.10) | 
| Suggests: | knitr, rmarkdown, testthat (≥ 3.0.0) | 
| Config/testthat/edition: | 3 | 
| NeedsCompilation: | no | 
| Packaged: | 2024-04-02 19:05:39 UTC; JCAYEN | 
| Author: | Joelle Cayen [aut, cre] | 
| Maintainer: | Joelle Cayen <joelle.cayen@phac-aspc.gc.ca> | 
| Repository: | CRAN | 
| Date/Publication: | 2024-04-02 22:35:03 UTC | 
Canadian Census Division Boundary Data
Description
Provides geospatial information for all Canadian census divisions.
Usage
CD
Format
A data frame with 293 rows and 7 variables:
- CDNAME
- Census Division names 
- PRUID
- ID column for each province 
- rmapshaperid
- id for geometry 
- population_2021
- Population from 2021 Census 
- PT
- province or territory 
- PRNAME
- Province name 
- geometry
- map geometry 
...
Canadian Census Sub Division Boundary Data
Description
Provides geospatial information for all Canadian census sub divisions.
Usage
CSD
Format
A data frame with 5161 rows and 9 variables:
- CDNAME
- Census Division names 
- PRUID
- ID column for each province 
- CDUID
- Census Division ID 
- CMAUID
- CMA ID 
- rmapshaperid
- id for geometry 
- population_2021
- Population from 2021 Census 
- PT
- province or territory 
- PRNAME
- Province name 
- geometry
- map geometry 
...
Canadian FSA Boundary Data
Description
Provides geospatial information for all Canadian Forward sortation areas (FSA).
Usage
FSA
Format
A data frame with 1614 rows and 6 variables:
- CFSAUID
- ID column for each FSA code 
- PRNAME
- Province name 
- PRUID
- ID column for each province 
- PT
- province or territory 
- rmapshaperid
- id for geometry 
- geometry
- map geometry 
...
Canadian HR Boundary Data
Description
Provides geospatial information for all Health Regions areas (HR).
Usage
HR
Format
A data frame with 104 rows and 8 variables:
- HRID
- ID column for each HR code 
- HRENGNAME
- Health Region english name 
- HRFRNAME
- Health Region french name 
- rmapshapeid
- id for geometry 
- geometry
- map geometry 
- PT
- province or territory 
- PRNAME
- Province name 
- PRUID
- ID column for each province 
...
Canadian Province Boundary Data
Description
Provides geospatial information for all 13 Canadian provinces and territories.
Usage
PROV
Format
A data frame with 13 rows and 12 variables:
- PREABBR
- Province abbreviated English 
- PRENAME
- Province name English 
- PRFABBR
- Province abbreviated French 
- PRFNAME
- Province name French 
- PRNAME
- Province name 
- PRUID
- ID column for each province 
- PT
- province or territory 
- region
- national region 
- X
- center of shape x axis 
- Y
- center of shape y axis 
- rmapshaperid
- id for geometry 
- geometry
- map geometry 
...
Canadian Regions Boundary Data
Description
Provides geospatial information for all 4 regions of Canada (Central, Eastern, Western, and Northern).
Usage
REG
Format
A data frame with 13 rows and 12 variables:
- PREABBR
- Province abbreviated English 
- PRENAME
- Province name English 
- PRFABBR
- Province abbreviated French 
- PRFNAME
- Province name French 
- PRNAME
- Province name 
- PRUID
- ID column for each province 
- PT
- province or territory 
- region
- national region 
- X
- center of shape x axis 
- Y
- center of shape y axis 
- rmapshaperid
- id for geometry 
- geometry
- map geometry 
...
Transforming map coordinates
Description
Converts your longitude and latitude coordinates to match the maps to properly overlay.
Usage
coord_transform(data, long, lat)
Arguments
| data | a data set with long and lat coordinates | 
| long | the longitude variable name | 
| lat | the latitude variable name | 
Value
Your coordinates transformed.
Map coordinate system
Description
Used to visualize simple feature (sf) objects. Required to plot geometry objects.
Usage
crs_coord()
Value
a coordinate system for mapping
Mapping Census Division data
Description
Maps CD data using Statistics Canada CD shape file.
Usage
geom_cd(data = CD, fill = "PRNAME", colour = "white", size = 0.2)
Arguments
| data | a data set with geometry variable | 
| fill | the color fill variable | 
| colour | outline color, default is NA | 
| size | size of outline | 
Value
census division map.
Mapping Census Sub Division data
Description
Maps CSD data using Statistics Canada CSD shape file.
Usage
geom_csd(data = CSD, fill = "PRNAME", colour = "white", size = 0.2)
Arguments
| data | a data set with geometry variable | 
| fill | the color fill variable | 
| colour | outline color, default is NA | 
| size | size of outline | 
Value
census subdivision map.
Mapping FSA data
Description
Maps FSA data using Statistics Canada FSA shape file.
Usage
geom_fsa(data = FSA, fill = "PRNAME", colour = "white", size = 0.2)
Arguments
| data | a data set with geometry variable | 
| fill | the color fill variable | 
| colour | outline color, default is NA | 
| size | size of outline | 
Value
FSA map.
Mapping HR data
Description
Maps HR data using Statistics Canada HR shape file.
Usage
geom_hr(data = HR, fill = "PRNAME", colour = "white", size = 0.2)
Arguments
| data | a data set with geometry variable | 
| fill | the color fill variable | 
| colour | outline color, default is NA | 
| size | size of outline | 
Value
HR map.
Mapping provincial data
Description
Maps provincial data using Statistics Canada province shape file.
Usage
geom_prov(data = PROV, fill = "PT", colour = NA, size = 0.1)
Arguments
| data | a data set with geometry variable | 
| fill | the color fill variable | 
| colour | outline color, default is NA | 
| size | size of outline | 
Value
Provincial map.
Mapping regional data
Description
Maps regional data using Statistics Canada province shape file.
Usage
geom_reg(data = REG, fill = "region", colour = NA, size = 0.1)
Arguments
| data | a data set with geometry variable | 
| fill | the color fill variable | 
| colour | outline color, default is NA | 
| size | size of outline | 
Value
Regional map.
Province labels
Description
Adds text labels in the center of each province with light gray bubble.
Usage
label_prov(
  data = PROV,
  label = "PT",
  colour = "grey20",
  size = 3,
  outline = NA,
  alpha = 0.7
)
Arguments
| data | a data set with geometry variable | 
| label | the label variable | 
| colour | label color | 
| size | label size | 
| outline | outline color | 
| alpha | transparency | 
Value
Provincial map labels
Regional labels
Description
Adds text labels in the center of each region with light gray bubble.
Usage
label_reg(data = REG, label = "region", colour = "grey20", size = 4)
Arguments
| data | a data set with geometry variable | 
| label | the label variable | 
| colour | label color | 
| size | label size | 
Value
Regional map labels.
Color Palettes Line Color
Description
Create a custom number of colors to use for graphing or mapping based on preset color palettes.
Usage
scale_color_map(palette, num, na.value = "grey90", rev = FALSE)
Arguments
| palette | color palette name | 
| num | number of colors to create | 
| na.value | a color value for NA, defaults to light gray | 
| rev | condition to reverse the order of the colors | 
Value
a ggplot color palette
Color Palettes Fill
Description
Create a custom number of colors to use for graphing or mapping based on preset color palettes.
Usage
scale_fill_map(palette, num, na.value = "grey90", rev = FALSE)
Arguments
| palette | color palette name | 
| num | number of colors to create | 
| na.value | a color value for NA, defaults to light gray | 
| rev | condition to reverse the order of the colors | 
Value
a ggplot color palette
Province text
Description
Adds text labels in the center of each province.
Usage
text_prov(data = PROV, label = "PT", colour = "grey20", size = 3)
Arguments
| data | a data set with geometry variable | 
| label | the label variable | 
| colour | text color | 
| size | text size | 
Value
Provincial map labels
Plot theme - map
Description
Blank theme to apply for mapping using ggplot2.
Usage
theme_map(base_size = 9, base_family = "")
Arguments
| base_size | size for text | 
| base_family | font for text | 
Value
A blank theme for ggplot
Plot theme - Wallis
Description
Custom theme to apply for plotting using ggplot2.
Usage
theme_wallis()
Value
A theme for ggplot