Skip to content

Instantly share code, notes, and snippets.

@mandel59
Created August 5, 2023 14:42
Show Gist options
  • Save mandel59/75c2bbf70a2c90c60cdcd1f2e41fd9ab to your computer and use it in GitHub Desktop.
Save mandel59/75c2bbf70a2c90c60cdcd1f2e41fd9ab to your computer and use it in GitHub Desktop.

Revisions

  1. mandel59 created this gist Aug 5, 2023.
    11 changes: 11 additions & 0 deletions matsudo-population-density.erq
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,11 @@
    -- erq <matsudo-population-density.erq > matsudo-population-density.svg
    topojson_feature(readfile('r2ka12207.topojson'), 'town')
    {*, unpack properties {KEY_CODE, AREA, JINKO}}
    {*, population_density: JINKO / AREA * 1000000}
    output vega lite svg with
    projection mercator,
    mark geoshape,
    encoding {
    color: population_density q {title: "人口密度[人/km²]"}
    },
    options {width: 800, height: 600};;
    1 change: 1 addition & 0 deletions matsudo-population-density.svg
    Loading
    Sorry, something went wrong. Reload?
    Sorry, we cannot display this file.
    Sorry, this file is invalid so it cannot be displayed.