-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
get_municipalities
argument codes_as_character
seems to not work
#46
Comments
I was the one fixing issue #38 with PR #39, so IIRC Maybe this could be fixed by either
What does @muuankarski think? |
This was actually because of missing |
Thank you @pitkant for your fast reply. I have to admit that I was not aware of
|
Hello, Unfortunately
Current environment is this:
|
Hi, I had to make a quick resubmission as geofi was archived from CRAN. Sid
not have Time to properly test this. Will have a Look and can make a
resubmissio soon.
Beat,
markus
to 2. marrask. 2023 klo 12.15 Sampo Vesanen ***@***.***>
kirjoitti:
… Hello,
Unfortunately codes_as_character still does not work in geofi_10.0.10.
`> geofi::get_municipalities(codes_as_character = TRUE) %>%
- dplyr::select(kunta)
Requesting response from:
http://geo.stat.fi/geoserver/wfs?service=WFS&version=1.0.0&request=getFeature&typename=tilastointialueet%3Akunta4500k_2023
Data is licensed under: Attribution 4.0 International (CC BY 4.0)
Simple feature collection with 309 features and 1 field
Geometry type: MULTIPOLYGON
Dimension: XY
Bounding box: xmin: 83747.59 ymin: 6637032 xmax: 732907.7 ymax: 7776431
Projected CRS: ETRS89 / TM35FIN(E,N)
First 10 features:
kunta geom
1 5 MULTIPOLYGON (((366787.9 70...
2 9 MULTIPOLYGON (((382543.4 71...
3 10 MULTIPOLYGON (((343298.2 69...
4 16 MULTIPOLYGON (((436139.7 67...
5 18 MULTIPOLYGON (((426631 6720...
6 19 MULTIPOLYGON (((263938.3 67...
7 20 MULTIPOLYGON (((328844.1 67...
8 35 MULTIPOLYGON (((176190.4 67...
9 43 MULTIPOLYGON (((92735.28 67...
10 46 MULTIPOLYGON (((600317.4 69...
Warning message:
Coercing CRS to epsg:3067 (ETRS89 / TM35FIN)
muns <- geofi::get_municipalities(codes_as_character = TRUE) %>%
- dplyr::select(kunta)
Requesting response from:
http://geo.stat.fi/geoserver/wfs?service=WFS&version=1.0.0&request=getFeature&typename=tilastointialueet%3Akunta4500k_2023
Data is licensed under: Attribution 4.0 International (CC BY 4.0)
Warning message:
Coercing CRS to epsg:3067 (ETRS89 / TM35FIN)
sapply(muns, class)
$kunta
[1] "integer"
$geom
[1] "sfc_MULTIPOLYGON" "sfc" `
—
Reply to this email directly, view it on GitHub
<#46 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AALUL6CX55BXBJXCAM4W7NTYCNXDFAVCNFSM6AAAAAAZYLKNOCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTOOJQGQ2DCOJXG4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@sampoves Yes, it would seem that what You could use Also argument documentation could be clarified, or then it could be made so that all codes would indeed be characters? |
Hello @muuankarski and @pitkant, many thanks for your replies. We've been through this and I do have to admit that I just didn't remember what we've been conversing about. Apologies and thank you for the friendly reminder about the fields and as you said I do think it is tiny bit confusing to have a prominent field Many thanks for the swift communication and maintenance of |
Hello,
It would seem to me that the argument
codes_as_character
for functionget_municipalities
does not work ingeofi_1.0.9
:codes_as_character
is FALSEcodes_as_character
is TRUEChanging the argument value does not introduce leading zeroes to the column
kunta
and it does not change the column type to character.My session:
Additionally, what's peculiar is that the command
geofi::get_municipalities(codes_as_character = FALSE)
works without any specific year, butcodes_as_character
= TRUE requires an explicit year argument:geofi::get_municipalities(year = 2022, codes_as_character = TRUE)
. This is obviously a separate matter, will be opening an issue for it too if I find the time.The text was updated successfully, but these errors were encountered: