Skip to contents

Add geo granularity levels to all sides

Usage

cast_geo(year = NULL, names = TRUE)

Arguments

year

Which year the codes are valid from. If NULL then current year will be selected.

names

Include names. Default is TRUE

Value

A dataset of class data.table representing the spreading of different geographical levels from lower to higher levels ie. from enumeration area codes to county codes, for the selected year.

Examples

 DT <- cast_geo(2019)
#> Start casting geo codes from API ...
#> No valid codes for geo level levekaar for year 2019, skipped
#> Data for grunnkrets to bydel in 2019 have 1605 rows
#> Data for grunnkrets to levekaar in 2019 have 0 rows
#> Data for grunnkrets to kommune in 2019 have 14485 rows
#> Data for kommune to okonomisk in 2019 have 422 rows
#> Data for kommune to fylke in 2019 have 421 rows