Skip to contents

Indexing

Convert between coordinates and A5 cell indices.

a5_lonlat_to_cell()
Convert coordinates to A5 cell indices
a5_cell_to_lonlat()
Convert A5 cell indices to coordinates

Cell type

The a5_cell vector type and helpers.

a5_cell() is_a5_cell() as_a5_cell() a5_is_valid()
A5 Cell Index Vector
a5_u64_to_hex() a5_hex_to_u64()
Coerce between hex strings and A5 cell vectors

Arrow & Parquet

Lossless conversion between a5_cell and Arrow uint64 arrays.

a5_cell_from_arrow() a5_cell_to_arrow()
Convert between a5_cell and Arrow uint64 arrays

Hierarchy

Navigate the cell hierarchy across resolutions.

a5_get_resolution()
Get the resolution of A5 cell indices
a5_cell_to_parent()
Navigate to parent cell(s)
a5_cell_to_children()
Get child cells
a5_get_res0_cells()
Get all resolution-0 root cells

Geometry & info

Cell boundaries, areas, counts, and distances.

a5_cell_to_boundary()
Get cell boundary polygons
a5_cell_distance()
Distance between cell centroids
a5_cell_area()
Cell area at a given resolution
a5_get_num_cells()
Total number of cells at a given resolution
a5_get_num_children()
Number of children between two resolutions

Traversal

Neighbourhood and distance-based cell selection.

a5_grid_disk()
Cells within k hops of a cell
a5_spherical_cap()
Cells within a great-circle radius

Compact & uncompact

Compress and expand sets of cells.

a5_compact()
Compact a set of A5 cells
a5_uncompact()
Uncompact a set of A5 cells to a target resolution

Grid generation

Generate grids of cells covering an area.

a5_grid()
Generate a grid of A5 cells covering an area

Configuration

Thread control for parallel processing.

a5_set_threads() a5_get_threads()
Set the number of threads used by a5R

wk integration

Methods for the wk geometry framework.

wk_handle(<a5_cell>) wk_crs(<a5_cell>)
wk methods for a5_cell