Macaw.Frame.Maps.Voronoi (macaw_frame v0.1.0)

Copy Markdown View Source

maps.voronoi (spec/13 §6.7), a map layer: each projected point's Voronoi cell bounded by the plot, outlined in axis and filled by category when fill_by asks, with the points' dashed hull from delaunay(output: "hull") on demand. A pick on a cell writes its point's identity, so the cells are the points' nearest-neighbor hit areas. Copied from the gallery's scatter plot's Voronoi (examples/lib/examples/charts/scatter_plot.ex).

iex> Macaw.Frame.Maps.Voronoi.id()
"maps.voronoi"

Summary

Functions

What it draws, for a person and a builder's library.

Its fixture (spec/14 §1): the cities' cells, filled by country, with the hull.

The fragment: projection, then voronoi, under a path layer, and the hull's.

The fragment's id in the catalog store.

What the fragment is: a whole design, or layers placed in one.

Its namespace (spec/13 §2).

Its parameters (spec/13 §6.7).

Its slot: points, a longitude and a latitude, an optional category and identity.

Functions

doc()

@spec doc() :: String.t()

What it draws, for a person and a builder's library.

fixtures()

@spec fixtures() :: [map()]

Its fixture (spec/14 §1): the cities' cells, filled by country, with the hull.

fragment()

@spec fragment() :: map()

The fragment: projection, then voronoi, under a path layer, and the hull's.

id()

@spec id() :: String.t()

The fragment's id in the catalog store.

kind()

@spec kind() :: :design | :layers

What the fragment is: a whole design, or layers placed in one.

namespace()

@spec namespace() :: :charts | :maps | :diagrams

Its namespace (spec/13 §2).

parameters()

@spec parameters() :: [{String.t(), map()}]

Its parameters (spec/13 §6.7).

slots()

@spec slots() :: %{required(String.t()) => map()}

Its slot: points, a longitude and a latitude, an optional category and identity.