Skip to content

Releases

local-data-viz 1.4.0

Choose a tag to compare

@ultrathinker ultrathinker released this 05 Oct 14:24

Added

  • Row filters. The plan can keep only some rows: { "column": "department", "op": "=", "value": "emergency" }, or the last
    months of the data: { "column": "visit_time", "op": "last", "n": 3, "unit": "month" }. Operators: =, !=, <, <=, >, >=,
    between, in, not_in, is_null, not_null, contains, starts_with, last. Filters can be given for the whole page
    (per dataset), for one chart or for one explorer, and combine with AND. They are plain JSON checked against the columns, never SQL
    text, and every value is quoted. Charts, explorers and key numbers are computed from the kept rows only; a histogram and the
    first-to-last sentence of a line chart use the range of the kept rows; the page says above each chart which rows it shows; a
    filter that leaves no rows is reported by the build.
  • Charts can be saved as an SVG file or a PNG picture; tooltips on every mark; a line chart follows the pointer with a guide at the
    nearest date and every line's value there.

Changed

  • The page draws its charts itself, as plain SVG, in about a thousand lines of readable code. The bundled Vega, Vega-Lite and
    Vega-Embed (868 KB of minified code) are gone: nothing third-party is shipped, the page's content policy no longer allows eval,
    and a chart spec now holds only titles as text. The numbers on every chart are unchanged.
  • Numbers are cut to 12 significant digits before they are rounded to six places, so building twice from the same data gives the same
    page: an average that fell exactly between two roundings used to come out one way or the other depending on the order DuckDB added
    the rows in.
  • One number format per axis (0, 10K, 20K rather than a mix of 5,000 and 10K); scatter plots follow their data instead of
    starting at the next round number.