Skip to content

Commit 018dc00

Browse files
committed
Merge branch 'master' of https://github.com/boshek/bcmaps into boshek-master
2 parents b3e5d82 + 10e5eb9 commit 018dc00

10 files changed

Lines changed: 94 additions & 2 deletions

File tree

R/bc_hyd_zn.R

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Copyright 2016 Province of British Columbia
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS,
10+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
# See the License for the specific language governing permissions and limitations under the License.
12+
#
13+
#' Hydrologic Zone Boundaries of British Columbia
14+
#'
15+
#' Hydrologic zone boundaries were digitized from 1:600,000 hardcopy maps.
16+
#' Coastline & islands were copied from 1:50K BC WSA. Linework updated January 2003.
17+
#' Polygons & Regions built September 20, 2004. Boundaries accuracy is +/- 1 kilometre based
18+
#' on hydrologic maps, graphical plots, & previous definitions.
19+
#'
20+
#'
21+
#' @format Zones that represent areas of homogeneous hydrologic and geomorphological characteristics
22+
#'
23+
#'
24+
#' @source Original data from
25+
#' \href{https://catalogue.data.gov.bc.ca/dataset/hydrology-hydrologic-zone-boundaries-of-british-columbia}{DataBC},
26+
#' under the
27+
#' \href{http://www.data.gov.bc.ca/local/dbc/docs/license/OGL-vbc2.0.pdf}{Open
28+
#' Government License - British Columbia}.
29+
30+
"bc_hyd_zn"

README.Rmd

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ install_github("bcgov/bcmaps", build_vignettes = TRUE)
4747

4848
### Usage
4949

50-
At the moment, there are fourteen layers available:
50+
At the moment, there are fifteen layers available:
5151

5252
- `bc_bound`: Coarse provincial boundary of British Columbia (1:7.5M scale).
5353

@@ -81,6 +81,8 @@ At the moment, there are fourteen layers available:
8181

8282
- `water_precincts`: Boundaries of British Columbia's Water Management Precincts.
8383

84+
- `bc_hyd_zn`: Hydrologic Zone Boundaries of British Columbia.
85+
8486
To load any of them, simply type `data(layer_name)`, where `layer_name` is the
8587
name of the layer of interest. Then you can use the data as you would any `sp`
8688
object.

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ install_github("bcgov/bcmaps", build_vignettes = TRUE)
2727

2828
### Usage
2929

30-
At the moment, there are fourteen layers available:
30+
At the moment, there are fifteen layers available:
3131

3232
- `bc_bound`: Coarse provincial boundary of British Columbia (1:7.5M scale).
3333

@@ -61,6 +61,8 @@ At the moment, there are fourteen layers available:
6161

6262
- `water_precincts`: Boundaries of British Columbia's Water Management Precincts.
6363

64+
- `bc_hyd_zn`: Hydrologic Zone Boundaries of British Columbia.
65+
6466
To load any of them, simply type `data(layer_name)`, where `layer_name` is the name of the layer of interest. Then you can use the data as you would any `sp` object.
6567

6668
A couple of simple examples:
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
HYD_BC_H_Z
2+
README.txt
3+
contents_of_order.txt
4+
licence.txt
5+
HYD_BC_H_Z.html
766 KB
Binary file not shown.
198 KB
Binary file not shown.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
## BC Hydrologic Zones
2+
3+
The file `BC_hydrologic_zones.zip` contains the British Columbia Hydrologic Zone Boundaries, downloaded from [DataBC](https://catalogue.data.gov.bc.ca/dataset/hydrology-hydrologic-zone-boundaries-of-british-columbia) under the ([Open Government License - British Columbia](http://www.data.gov.bc.ca/local/dbc/docs/license/OGL-vbc2.0.pdf)).
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Copyright 2017 Province of British Columbia
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS,
10+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
# See the License for the specific language governing permissions and limitations under the License.
12+
13+
library("sp")
14+
library("rgdal")
15+
library("devtools")
16+
17+
hydrologic_zip <- "data-raw/hydrologic_zones/BC_hydrologic_zones.zip"
18+
19+
unzip(hydrologic_zip , exdir = "data-raw/hydrologic_zones")
20+
21+
bc_hyd_zn <- readOGR(dsn = "data-raw/hydrologic_zones/HYD_BC_H_Z",
22+
layer = "HYD_BC_H_Z_polygon", stringsAsFactors = FALSE)
23+
24+
bc_hyd_zn <- spTransform(bc_hyd_zn, "+init=epsg:3005")
25+
26+
use_data(bc_hyd_zn, overwrite = TRUE, compress = "xz")

data/bc_hyd_zn.rda

490 KB
Binary file not shown.

man/bc_hyd_zn.Rd

Lines changed: 24 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)