observablehq / observablehq/plot

waffle unit: auto

Open
#2,214 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
HTML
Stars
5.4k
Forks
244
PR merge metrics
No merged PRs in 30d

Description

When a waffle mark depicts large values, it might become invisible because the area for each "dot" becomes infinitesimal. This suggests that the default unit should be "auto" instead of 1, and adapt to the available area.

To avoid unwanted surprises, this should not be too progressive (we don't want this to kick in for values such as 0.001 or 1000), but only happen only if the base dot is infinitesimal or super-extra-huge. It should also only work with powers of 10 (or maybe powers of 1000).

It should also be shared between all waffle marks (but that should be OK given that it will be based on the available area = bandwidth × bar length). We might want a way to surface it to the user (something like an internal scale, maybe?).

Image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the waffle mark entry point and tracing how the current unit value determines dot size from the available area. Define and test the boundaries for automatic scaling, including supported powers and cases where scaling should not occur; the issue is done when large-value waffle marks remain visible without changing ordinary values unexpectedly.

Written by the indexing model from the issue text.

Assessment

Domain
data-visualization
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.