New function adjacency() for cell-based neighbourhood lookup, replacing the
old matrix shift functions (tl(), bl(), tr(), br(), la(), ta(),
ra(), ba()). The new function takes dimension and cell arguments
consistent with the rest of vaster, returning a matrix of neighbour cell
indices with named columns for direction. Supports "queen", "rook", and
"bishop" neighbourhood types.
Renamed ts() and te() to gdal_ts() and gdal_te() to avoid masking
stats::ts().
We now have internal functions col_from_x_c() and row_from_y_c(), x_from_col_c() and y_from_row_c() that use C under the hood, these currently accept and return 0-based indexes.
Package now requires compilation, with the R C api.
Speed up x_from_col and y_from_row, fixes #19.
New functions rasterio_idx() (was affinity::raster_to_rasterio), rasterio0 (was affinity::raster_io0) and
internal for now rasterio_crop().
differences are
New functions tl(), ta(), tr(), ra(), br(), ba(). br(), la()
which are top left, top, top right, right, bottom right, bottom, bottom right,
left. These are different from the affinity ones because they don't keep the
extra rows and columns (the variants in affinity might become options with
these). The 'a' means adjacent, we can't use t(), r(), l(), b() and top, right,
left, bottom seems weird.
New function from_xyz() to return a grid (dimension and extent) derived from
"XYZ" points, basically are the points (in whatever order, and may be
incomplete) on a regular grid within the rounding threshold of the 'digits'
parameter.
New functions ts(), te(), and ts_te() to format dimension,extent for use
with GDAL options.
plot_extent() is now vectorized, just give it xmin, xmax, ymin, ymax in that
order in vector, matrix, or data frame.
New function snap_extent() to replace spex::buffer_extent(), aliased to
buffer_extent() in this package.
Better argument consistency, dimension first, then extent.
New function extent_vrt() to obtain tile extents from VRT text.
New function vaster_listxyz() to convert extent, dimension, and optionally
data to trad image() format.
New function vaster_long() to convert extent, dimension, and optionally data
to long form XYZ in raster or trad matrix order.
All obvious raster functions now included (needs more testing).
Version bump to allow {grout} to depend on vaster for cell and extent ops.
Added a NEWS.md file to track changes to the package.