build_crossscale_index: Build cross-scale index structures for H3-based SCP workflows

View source: R/h3_hierarchy.R

build_crossscale_indexR Documentation

Build cross-scale index structures for H3-based SCP workflows

Description

Extends the basic hierarchy from build_h3_maps() into full ancestor, descendant and resolution-index mappings used by all multiscale selection and evaluation functions.

Usage

build_crossscale_index(maps)

Arguments

maps

The list returned by build_h3_maps().

Value

A list with elements:

  • res_levels

  • rows_by_res

  • pos_in_res

  • anc_at_res

  • desc_at_res

  • finer_rows_by_r0cell

Examples

h3_child  <- "8a2a1072b59ffff"
h3_parent <- "892a1072b5bffff"

h3_vec <- c(h3_parent, h3_child)
h3_res <- h3jsr::get_res(h3_vec, simple = TRUE)

maps <- build_h3_maps(s_or_h3 = h3_vec, res_vec = h3_res)

cs_idx <- build_crossscale_index(maps)

names(cs_idx)
cs_idx$res_levels


MultiscaleSCP documentation built on Oct. 14, 2026, 5:07 p.m.