rename_fude {fude}R Documentation

Rename the Fude Polygon data

Description

rename_fude() renames the 6-digit local government code of the list returned by read_fude() to the corresponding Japanese name in order to make the data human-friendly.

Usage

rename_fude(data, suffix = TRUE, romaji = NULL, quiet = FALSE)

Arguments

data

List of sf::sf() objects.

suffix

logical. If FALSE, suffixes such as "SHI" and "KU" in local government names are removed.

romaji

If not NULL, rename the local government name in romaji instead of Japanese. Romanji format is upper case unless specified.

  • "title": Title case.

  • "lower": Lower case.

  • "upper": Upper case.

quiet

logical. Suppress information about the data to be read.

Value

A list of sf::sf() objects.

See Also

read_fude().

Examples

path <- system.file("extdata", "castle.zip", package = "fude")
d <- read_fude(path, stringsAsFactors = FALSE, quiet = TRUE)
d2 <- rename_fude(d)
d2 <- rename_fude(d, suffix = FALSE)
d2 <- d |> rename_fude(romaji = "upper")


[Package fude version 0.3.5 Index]