Skip to contents

Adjacent blocks are defined as the blocks that are neighbours to the blocks that need to be merged, and that intersect them via a (Multi)LineString. We consider the blocks to merge one by one, from the smallest to the largest, merging them to the other blocks recursively.

Usage

merge_blocks(blocks, to_merge, method = "longest-intersection")

Arguments

blocks

Simple feature geometry representing all the blocks

to_merge

Indices of the blocks to merge

method

Strategy for merging, see merge_block()

Value

Blocks merged to the specified ones as a simple feature geometry