# `Macaw.Frame.Maps.Choropleth`
[🔗](https://github.com/dcoai/macaw_frame/blob/v0.1.0/lib/macaw/frame/maps/choropleth.ex#L1)

`maps.choropleth` (spec/13 §7.2), a second-cut map layer: each region's GeoJSON
`geometry` projected (`projection(field: geometry)`) into a `path` filled by its `value`
through `choropleth.color`, a `sequential` scale, or a `threshold` scale over
`thresholds`, along the theme's sequential ramp turned by `polarity`, with its legend.

**One slot, joined before the frame** (decision, macaw_frame#89): the contract's
regions are joined to their values by identity "by a derived source or the `join` the
page binds", so the frame reads one `regions` slot whose rows hold the region's `id`,
its `geometry` and its joined `value`; a frame joins no two slots (a join is macaw_data's
derived source, spec/13 §7.2). New in the second cut.

    iex> Macaw.Frame.Maps.Choropleth.id()
    "maps.choropleth"

# `doc`

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

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

# `fixtures`

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

Its fixture (spec/14 §1): six boxes of western Europe by a value, over the cities.

# `fragment`

```elixir
@spec fragment() :: map()
```

The fragment: projection of each geometry under one path layer and its color scale.

# `id`

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

The fragment's id in the catalog store.

# `kind`

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

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

# `namespace`

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

Its namespace (spec/13 §2).

# `parameters`

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

Its parameters (spec/13 §7.2).

# `slots`

```elixir
@spec slots() :: %{required(String.t()) =&gt; map()}
```

Its slot: `regions`, an identity, a GeoJSON geometry and the region's joined value.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
