get_kaz_oblasts_map: Get Oblasts & Cities of Republican Significance of Kazakhstan...

View source: R/get_kaz_map.R

get_kaz_oblasts_mapR Documentation

Get Oblasts & Cities of Republican Significance of Kazakhstan as sf polygons

Description

Returns Geographical features of Oblasts & Cities of Republican Significance of Kazakhstan - Map of All Administrative units level 1 (the principal units of a country) as polygons by specified codes or names or all of them in 2022 (default) or 2018 year.

Usage

get_kaz_oblasts_map(
                    KATO = NULL,       # Number
                    ADM1_EN = NULL,    # Character
                    ADM1_KK = NULL,    # Character
                    ADM1_RU = NULL,    # Character
                    ADM1_PCODE = NULL, # Character
                    ISO_3166_2 = NULL, # Character
                    crs = "+proj=lcc +lon_0=67 +lat_1=45 +lat_2=51 +ellps=krass",
                    Year = 2024L       # Integer
                    )

Arguments

KATO

A vector of Codes of Classifier of Administrative Territorial Objects (rus. KATO) for the required Oblasts & Cities of Republican Significance of Kazakhstan or NULL to get all of them.

ADM1_EN

A vector of Names of Administrative units level 1 on English for the required Oblasts & Cities of Republican Significance of Kazakhstan or NULL to get all of them.

ADM1_KK

A vector of Names of Administrative units level 1 on Kazakh (Cyrillic) characters for the required Oblasts & Cities of Republican Significance of Kazakhstan or NULL to get all of them.

ADM1_RU

A vector of Names of Administrative units level 1 on Russian (Cyrillic) characters for the required Oblasts & Cities of Republican Significance of Kazakhstan or NULL to get all of them.

ADM1_PCODE

A vector of modified Codes of Classifier of Administrative Territorial Objects (rus. KATO) for the required Oblasts & Cities of Republican Significance of Kazakhstan with 'KZ-' prefix or NULL to get all of them.

ISO_3166_2

A vector of Codes for the principal subdivisions coded in ISO 3166-2 or NULL to get all of them.

crs

A value of Coordinate Reference System as EPSG (SRID) number (for example, 2502) or proj4string from the PROJ.4 library (for example, "+proj=longlat +datum=WGS84" as a projection specifier or "+init=epsg:4326" as EPSG number) or NULL to get projection for A Lambert Conformal Conic (LCC) with Krasovsky 1940 ellipsoid. See Details.

Year

An integer of Year for Administrative-Territorial divisions of the Country: 2018 or 2024 (default).

Details

When filter Geographical features you can use some names of Oblasts & Cities of Republican Significance in English, Kazakh or Russian or National codes (ADM1_PCODE or KATO corresponding to level 1) or ISO International codes (ISO 3166-2 corresponding to level 1) (see kaz_adm1_sf).

Astana, Almaty and Shymkent are considered as region on this dataset.

Baykonyr (a city near the World's First Spaceport) are not considered on this dataset.

Simultaneous use of several types of geographic features codes or names in different languages is not allowed.

For use non-latin characters in filters you need run cat(stringi::stri_escape_unicode(x)) code R, for example, cat(stringi::stri_escape_unicode("\u0428\u044B\u043C\u043A\u0435\u043D\u0442 (\u049B\u0430\u043B\u0430)")) that is "Шымкент (қала)" or "Shymkent (city)" in Kazakh language. See stringi::stri_escape_unicode for details.

The Default Projection uses A Lambert Conformal Conic (LCC) with Krasovsky 1940 ellipsoid and First standard parallel - 45 N, Second standard parallel - 51 N, Longitude of projection center - 67 E, Latitude of projection center - 48 N.

Value

A sf object with the requested geographic geometries.

Author(s)

Alexander Rodionov a.rodionoff@gmail.com, ORCID = "0000-0003-2028-5421".

See Also

You can upload dataset kaz_adm1_sf for Oblasts & Cities of Republican Significance of Kazakhstan directly, but you must manually filter the Geographic Features you require and set the suitable Cartographic Projection.

For maps of Oblast & City of Republican Significance in 2022 Version please use function get_kaz_oblasts_map () or dataset kaz_adm1_sf.

For maps of Oblast & City of Republican Significance in 2018 Version please use function get_kaz_oblasts_map(Year = 2018L) or dataset kaz_adm1_2018_sf.

package vignette or vignette("making_maps", package = "geokz")

Other general polygon functions: get_kaz_rayons_map()

Examples


kaz <- get_kaz_oblasts_map()

plot(kaz["ADM1_EN"])

if (requireNamespace("dplyr","tmap", quietly = TRUE)) {

library(dplyr)
library(tmap)

# Western Regions

Western_Region <-
  get_kaz_oblasts_map(ADM1_EN = c(
    "Aktobe",
    "Atyrau",
    "Mangystau",
    "West Kazakhstan"
  ),
  crs = 2500) # Pulkovo 1942 / Gauss-Kruger CM 57E. See <https://epsg.io/2500>.

tmap::qtm(Western_Region,
          fill = "ADM1_EN",
          title = "Western Region of Kazakhstan")

# Simultaneous use of several types of International & National codes or
# names in different languages **is allowed** with binding geographic features

South_Region <-
  get_kaz_oblasts_map(ADM1_EN = c(
    "Almaty",
    "Almaty (city)")) |>
  dplyr::bind_rows(
    get_kaz_oblasts_map(ADM1_KK = c(                                             # Kazakh Language
      "\u0422\u04AF\u0440\u043A\u0456\u0441\u0442\u0430\u043D",                  # Turkestan Region
      "\u0428\u044B\u043C\u043A\u0435\u043D\u0442 (\u049B\u0430\u043B\u0430)"))  # Shymkent City
  ) |>                                                     # cat(stringi::stri_escape_unicode(x))
  dplyr::bind_rows(
    get_kaz_oblasts_map(ISO_3166_2 = c(
      "KZ-ZHA",
      "KZ-ZHT",
      "KZ-KZY"))
  )

tmap::qtm(
  South_Region,
  fill = "ADM1_KK",
  text = "ADM1_EN",
  title = "South Region of Kazakhstan",
  fill.title = "\u041e\u0431\u043b\u044b\u0441 / \u049a\u0430\u043b\u0430",
  projection = 2502
  )

}    # The end for {dplyr}, {magrittr} & {tmap} package

arodionoff/geokz documentation built on July 1, 2024, 9:02 p.m.