Movatterモバイル変換


[0]ホーム

URL:


rgugik

CRANR build statuscodecovLicense: MITDOI

rgugik is an R package for downloading open datafrom resources ofPolish HeadOffice of Geodesy and Cartography including:

It is also possible to geocode addresses or objects using thegeocodePL_get() function.

Corresponding functions

FunctionInputDastaset ENDataset PL
ortho_request(),tile_download()geometryOrthophotomapOrtofotomapa
geodb_download()voivodeshipGeneral Geographic DatabaseBaza Danych ObiektówOgólnogeograficznych
topodb_download()countyTopographic DatabaseBaza Danych Obiektów Topograficznych
emuia_download()communeRegister of Towns, Streets andAddressesEwidencja Miejscowości, Ulic iAdresów
egib_download()countyLand and Building RegisterEwidencja Gruntów i Budynków
geonames_download()typeState Register of Geographical NamesPaństwowy Rejestr Nazw Geograficznych
borders_get(),borders_download()typeState Register of BordersPaństwowy Rejestr Granic
parcel_get()parcel ID, coordinatesLocation of cadastral parcelsLokalizacja działek katastralnych
models3D_download()county3D models of buildingsModele 3D budynków
DEM_request(),tile_download()geometryDigital elevation modelsCyfrowe modele wysokościowe

There are the additional functions for obtaining digital terrainmodel:

The names of administrative units and their IDs are included in theseobjects:

Installation

You can install the released version fromCRAN with:

install.packages("rgugik")

You can install the development version fromGitHub with:

# install.packages("remotes")remotes::install_github("kadyb/rgugik")

Usage

Orthophotomap

library(rgugik)library(sf)library(stars)polygon_path=system.file("datasets/search_area.gpkg",package ="rgugik")polygon=read_sf(polygon_path)req_df=ortho_request(polygon)# select the oldest imagereq_df= req_df[req_df$year==2001, ]# print metadatat(req_df)#>             30#> sheetID     "N-33-130-D-b-2-3"#> year        "2001"#> resolution  "1"#> composition "RGB"#> sensor      "Satellite"#> CRS         "PL-1992"#> date        "2001-01-01"#> isFilled    "TRUE"#> URL         "https://opendata.geoportal.gov.pl/ortofotomapa/41/41_3756_N-33-130-D-b-2-3.tif"#> filename    "41_3756_N-33-130-D-b-2-3"#> seriesID    "41"# download imagetile_download(req_df)#> 1/1img=read_stars("41_3756_N-33-130-D-b-2-3.tif")plot(st_rgb(img),main =NULL)

Administrative boundaries

library(rgugik)library(sf)# get counties from opolskie voivodeship (TERYT 16)counties= county_namescounties= counties[substr(counties$TERYT,1,2)=="16","TERYT"]counties_geom=borders_get(TERYT = counties)plot(st_geometry(counties_geom),main ="Opolskie")

Vignettes

More advanced examples of the practical (step by step) use of thispackage can be found in the vignettes:

Acknowledgment

Head Office of Geodesy andCartography in Poland is the main source of the provided data. Thedata is made available in accordance with theActof May 17, 1989 Geodetic and Cartographic Law (amended on 16 April2020).

All datasets can be explored interactively using theGeoportal.

Contribution

Contributions to this package are welcome. The preferred method ofcontribution is through a GitHub pull request. Feel also free to contactus by creatinganissue. More detailed information can be found in theCONTRIBUTINGdocument.

Maintainers and contributors must follow this repository’sCODEOF CONDUCT.

Citation

To citergugik in publications, please use thefollowingarticle:

Dyba, K. and Nowosad, J. (2021). rgugik: Search and Retrieve Spatial Data from the Polish Head Office of Geodesy and Cartography in R. Journal of Open Source Software, 6(59), 2948, https://doi.org/10.21105/joss.02948

BibTeX version can be obtained withcitation("rgugik").

Related projects

If you don’t feel familiar with R, there is a similarQGIS tool in theEnviroSolutionsrepository.


[8]ページ先頭

©2009-2025 Movatter.jp