Comments (1)
I can reproduce this @Karine-Pigeon.
data <- tibble::tibble(
Row_ID = c(1, 2, 3, 4, 5, 6, 7, 8, 9, 10),
NotSure = c(9608, 9609, 9610, 9611, 9612, 9613, 9614, 9615, 9616, 9617),
Zone = c(10, 10, 10, 10, 10, 10, 9, 9, 9, 9),
UTMe = c(
361775,
361775,
307196,
307196,
328213,
328213,
636424,
636648,
636795,
637401
),
UTMn = c(
6011950,
6011950,
5979777,
5979777,
5984261,
5984261,
6161177,
6161270,
6161127,
6160851
),
UTMe1 = c(
361775,
361775,
307196,
307196,
328213,
328213,
636424,
636648,
636795,
637401
),
UTMn1 = c(
6011950,
6011950,
5979777,
5979777,
5984261,
5984261,
6161177,
6161270,
6161127,
6160851
)
)
data
#> # A tibble: 10 × 7
#> Row_ID NotSure Zone UTMe UTMn UTMe1 UTMn1
#> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
#> 1 1 9608 10 361775 6011950 361775 6011950
#> 2 2 9609 10 361775 6011950 361775 6011950
#> 3 3 9610 10 307196 5979777 307196 5979777
#> 4 4 9611 10 307196 5979777 307196 5979777
#> 5 5 9612 10 328213 5984261 328213 5984261
#> 6 6 9613 10 328213 5984261 328213 5984261
#> 7 7 9614 9 636424 6161177 636424 6161177
#> 8 8 9615 9 636648 6161270 636648 6161270
#> 9 9 9616 9 636795 6161127 636795 6161127
#> 10 10 9617 9 637401 6160851 637401 6160851
data2 <- bcmaps::utm_convert(data,
easting = "UTMe",
northing = "UTMn",
zone = "Zone")
data2
#> Simple feature collection with 10 features and 9 fields
#> Geometry type: POINT
#> Dimension: XY
#> Bounding box: xmin: 947410.6 ymin: 991848.1 xmax: 1057160 ymax: 1176079
#> Projected CRS: NAD83 / BC Albers
#> Row_ID NotSure Zone UTMe1 UTMn1 X Y UTMe UTMn
#> 9.1 7 9614 9 636424 6161177 947410.6 1175995.7 361775 6011950
#> 9.2 8 9615 9 636648 6161270 947637.9 1176079.3 361775 6011950
#> 9.3 9 9616 9 636795 6161127 947778.3 1175929.7 307196 5979777
#> 9.4 10 9617 9 637401 6160851 948370.4 1175627.1 307196 5979777
#> 10.1 1 9608 10 361775 6011950 1057160.4 1026400.1 328213 5984261
#> 10.2 2 9609 10 361775 6011950 1057160.4 1026400.1 328213 5984261
#> 10.3 3 9610 10 307196 5979777 1004137.0 991848.1 636424 6161177
#> 10.4 4 9611 10 307196 5979777 1004137.0 991848.1 636648 6161270
#> 10.5 5 9612 10 328213 5984261 1024888.8 997232.0 636795 6161127
#> 10.6 6 9613 10 328213 5984261 1024888.8 997232.0 637401 6160851
#> geometry
#> 9.1 POINT (947410.6 1175996)
#> 9.2 POINT (947637.9 1176079)
#> 9.3 POINT (947778.3 1175930)
#> 9.4 POINT (948370.4 1175627)
#> 10.1 POINT (1057160 1026400)
#> 10.2 POINT (1057160 1026400)
#> 10.3 POINT (1004137 991848.1)
#> 10.4 POINT (1004137 991848.1)
#> 10.5 POINT (1024889 997232)
#> 10.6 POINT (1024889 997232)
It looks like bcmaps
is returning the rows in ascending order of zone
+ X
, which based on the example in the function documentation is expected behaviour (row id number is also ordered+labelled by zone increments, e.g. 9.1
9.2
...). But the overwriting smells like a bug 🪳! 'cc @ateucher
from bcmaps.
Related Issues (20)
- Release bcmaps 1.1.0
- Drop raster and switch to using terra HOT 2
- Change `master` to `main` HOT 1
- Release bcmaps 1.2.0
- Drop sp support HOT 3
- Improve documentation for bc_bound() vs. bc_bound_hres() HOT 1
- Add citation to README? HOT 1
- Update add_points vignette with a ggplot2 example HOT 1
- Improvements to pkgdown site
- Missing part of map in airzone() HOT 19
- Hide uninformative plot captions in vignettes HOT 6
- Release bcmaps 2.0.0 HOT 3
- Ensure cded functions play well with terra
- Release bcmaps 2.1.0
- cded_raster deprication lifecycle message doesn't print properly HOT 4
- Release bcmaps 2.2.0
- `utm_convert()` drops tbl class
- utm_zone_lookup not found HOT 2
- function request: transform bc albers to long lat HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bcmaps.