set_level_data {geodimension}R Documentation

Set level data

Description

Set the data table of a given level.

Usage

set_level_data(gd, level_name, data)

## S3 method for class 'geodimension'
set_level_data(gd, level_name = NULL, data = NULL)

Arguments

gd

A geodimension object.

level_name

A string.

data

A tibble object.

Details

We can get the table, filter or transform the data and redefine the level table.

It is checked that the attributes that have been used in the relationships remain in the table.

Value

A geodimension object.

See Also

geolevel, get_level_data

Other geodimension definition functions: add_level(), geodimension(), transform_crs()

Examples


ld <- gd_us |>
  get_level_data(level_name = "county",
                 inherited = TRUE)

gd_us <- gd_us |>
  set_level_data(level_name = "county",
                 data = ld)


[Package geodimension version 2.0.0 Index]