Skip to contents

Tile plan defined by explicit per-tile bounds with no required uniformity in size or spacing. The bounds matrix is the canonical representation — there is no center-plus-dims formula. Always returns SpatExtent from [i]. Primary use case is as the output of adaptive spatial decomposition algorithms such as quadtrees on vector/point data.

Tile plan defined by explicit per-tile bounds with no required uniformity in size or spacing. Unlike grid-based plans, the bounds matrix is the canonical representation — tile positions are not computed from a formula.

The primary use case is adaptive spatial decomposition of vector/point data, where high-density regions require small tiles and sparse regions can use large tiles. See quadtreePlan() for the iterative construction workflow.

Slots

bounds

matrix. n x 4 matrix: xmin, xmax, ymin, ymax (one row per tile).

Note

@tile_dims is intentionally not populated. Any method that requires uniform tile dimensions will not work with freeTilePlan.

Setup

  • freeTilePlan() creates an empty instance.

  • $bounds<- sets the n x 4 bounds matrix (xmin, xmax, ymin, ymax). Setting bounds triggers reinitialization of @n, @dims, and @metadata.

  • $pad / + / - add spatial padding as with other plans.

Notes

  • @tile_dims is intentionally not populated. Operations that require uniform tile dimensions (e.g. extend = TRUE in getTile()) are not supported.

  • nrow() returns n, ncol() returns 1, length() returns n.

  • plot() works via the existing spatial extent preview.

Examples

tp <- freeTilePlan()
tp$bounds <- rbind(
    c(0,  50,  0,  50),
    c(50, 100, 0,  50),
    c(0,  50,  50, 100),
    c(50, 100, 50, 100)
)
length(tp)
#> [1] 4
tp[2]
#> [[1]]
#> SpatExtent : 50, 100, 0, 50 (xmin, xmax, ymin, ymax)
#> 
plot(tp)