Skip to content

Instantly share code, notes, and snippets.

@mbostock
Forked from mbostock/.block
Last active January 8, 2020 03:26
Show Gist options
  • Save mbostock/3757110 to your computer and use it in GitHub Desktop.
Save mbostock/3757110 to your computer and use it in GitHub Desktop.

Revisions

  1. mbostock revised this gist Oct 21, 2018. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions .block
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,4 @@
    license: gpl-3.0
    border: no
    height: 960
    redirect: https://beta.observablehq.com/@mbostock/d3-azimuthal-equidistant
  2. mbostock revised this gist May 15, 2017. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as [d3.geo.azimuthalEquidistant](https://github.com/mbostock/d3/wiki/Geo-Projections#wiki-azimuthalEquidistant).
    The [azimuthal equidistant projection](https://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as [d3.geoAzimuthalEquidistant](https://github.com/d3/d3-geo/blob/master/README.md#geoAzimuthalEquidistant).
  3. mbostock revised this gist May 15, 2017. 2 changed files with 16 additions and 25 deletions.
    2 changes: 2 additions & 0 deletions .block
    Original file line number Diff line number Diff line change
    @@ -1 +1,3 @@
    license: gpl-3.0
    border: no
    height: 960
    39 changes: 14 additions & 25 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -1,11 +1,6 @@
    <!DOCTYPE html>
    <meta charset="utf-8">
    <style>

    body {
    background: #fcfcfa;
    }

    .stroke {
    fill: none;
    stroke: #000;
    @@ -20,7 +15,7 @@
    fill: none;
    stroke: #777;
    stroke-width: .5px;
    stroke-opacity: .5;
    stroke-opacity: 0.5;
    }

    .land {
    @@ -30,33 +25,29 @@
    .boundary {
    fill: none;
    stroke: #fff;
    stroke-width: .5px;
    stroke-width: 0.5px;
    }

    </style>
    <body>
    <script src="//d3js.org/d3.v3.min.js"></script>
    <script src="//d3js.org/topojson.v1.min.js"></script>
    <svg width="960" height="960"></svg>
    <script src="https://d3js.org/d3.v4.min.js"></script>
    <script src="https://unpkg.com/topojson-client@3"></script>
    <script>

    var width = 960,
    height = 960;
    var svg = d3.select("svg"),
    width = +svg.attr("width"),
    height = +svg.attr("height");

    var projection = d3.geo.azimuthalEquidistant()
    var projection = d3.geoAzimuthalEquidistant()
    .scale(150)
    .translate([width / 2, height / 2])
    .rotate([122.4194, -37.7749])
    .clipAngle(180 - 1e-3)
    .precision(.1);
    .precision(0.1);

    var path = d3.geo.path()
    var path = d3.geoPath()
    .projection(projection);

    var graticule = d3.geo.graticule();

    var svg = d3.select("body").append("svg")
    .attr("width", width)
    .attr("height", height);

    svg.append("defs").append("path")
    .datum({type: "Sphere"})
    .attr("id", "sphere")
    @@ -71,11 +62,11 @@
    .attr("xlink:href", "#sphere");

    svg.append("path")
    .datum(graticule)
    .datum(d3.geoGraticule10())
    .attr("class", "graticule")
    .attr("d", path);

    d3.json("/mbostock/raw/4090846/world-50m.json", function(error, world) {
    d3.json("https://unpkg.com/world-atlas/world/50m.json", function(error, world) {
    if (error) throw error;

    svg.insert("path", ".graticule")
    @@ -89,6 +80,4 @@
    .attr("d", path);
    });

    d3.select(self.frameElement).style("height", height + "px");

    </script>
  4. mbostock revised this gist Feb 9, 2016. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions .block
    Original file line number Diff line number Diff line change
    @@ -0,0 +1 @@
    license: gpl-3.0
  5. mbostock revised this gist Oct 31, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -35,8 +35,8 @@

    </style>
    <body>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/topojson/1.6.19/topojson.min.js"></script>
    <script src="//d3js.org/d3.v3.min.js"></script>
    <script src="//d3js.org/topojson.v1.min.js"></script>
    <script>

    var width = 960,
  6. mbostock revised this gist Jun 11, 2015. 1 changed file with 4 additions and 2 deletions.
    6 changes: 4 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -35,8 +35,8 @@

    </style>
    <body>
    <script src="http://d3js.org/d3.v3.min.js"></script>
    <script src="http://d3js.org/topojson.v1.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/topojson/1.6.19/topojson.min.js"></script>
    <script>

    var width = 960,
    @@ -76,6 +76,8 @@
    .attr("d", path);

    d3.json("/mbostock/raw/4090846/world-50m.json", function(error, world) {
    if (error) throw error;

    svg.insert("path", ".graticule")
    .datum(topojson.feature(world, world.objects.land))
    .attr("class", "land")
  7. mbostock revised this gist May 13, 2013. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -36,7 +36,7 @@
    </style>
    <body>
    <script src="http://d3js.org/d3.v3.min.js"></script>
    <script src="http://d3js.org/topojson.v0.min.js"></script>
    <script src="http://d3js.org/topojson.v1.min.js"></script>
    <script>

    var width = 960,
    @@ -77,7 +77,7 @@

    d3.json("/mbostock/raw/4090846/world-50m.json", function(error, world) {
    svg.insert("path", ".graticule")
    .datum(topojson.object(world, world.objects.land))
    .datum(topojson.feature(world, world.objects.land))
    .attr("class", "land")
    .attr("d", path);

  8. mbostock revised this gist Mar 23, 2013. 1 changed file with 0 additions and 0 deletions.
    Binary file modified thumbnail.png
    Loading
    Sorry, something went wrong. Reload?
    Sorry, we cannot display this file.
    Sorry, this file is invalid so it cannot be displayed.
  9. mbostock revised this gist Mar 23, 2013. 1 changed file with 34 additions and 27 deletions.
    61 changes: 34 additions & 27 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -2,34 +2,35 @@
    <meta charset="utf-8">
    <style>

    .background {
    fill: #a4bac7;
    body {
    background: #fcfcfa;
    }

    .foreground {
    .stroke {
    fill: none;
    stroke: #333;
    stroke-width: 1.5px;
    stroke: #000;
    stroke-width: 3px;
    }

    .fill {
    fill: #fff;
    }

    .graticule {
    fill: none;
    stroke: #fff;
    stroke: #777;
    stroke-width: .5px;
    }

    .graticule :nth-child(2n) {
    stroke-dasharray: 2,2;
    stroke-opacity: .5;
    }

    .land {
    fill: #d7c7ad;
    stroke: #766951;
    fill: #222;
    }

    .boundary {
    fill: none;
    stroke: #a5967e;
    stroke: #fff;
    stroke-width: .5px;
    }

    </style>
    @@ -39,10 +40,13 @@
    <script>

    var width = 960,
    height = 500;
    height = 960;

    var projection = d3.geo.azimuthalEquidistant()
    .clipAngle(180 - 1e-3);
    .scale(150)
    .translate([width / 2, height / 2])
    .clipAngle(180 - 1e-3)
    .precision(.1);

    var path = d3.geo.path()
    .projection(projection);
    @@ -53,33 +57,36 @@
    .attr("width", width)
    .attr("height", height);

    svg.append("path")
    svg.append("defs").append("path")
    .datum({type: "Sphere"})
    .attr("class", "background")
    .attr("id", "sphere")
    .attr("d", path);

    svg.append("g")
    .attr("class", "graticule")
    .selectAll("path")
    .data(graticule.lines)
    .enter().append("path")
    .attr("d", path);
    svg.append("use")
    .attr("class", "stroke")
    .attr("xlink:href", "#sphere");

    svg.append("use")
    .attr("class", "fill")
    .attr("xlink:href", "#sphere");

    svg.append("path")
    .datum({type: "Sphere"})
    .attr("class", "foreground")
    .datum(graticule)
    .attr("class", "graticule")
    .attr("d", path);

    d3.json("/d/4090846/world-110m.json", function(error, world) {
    d3.json("/mbostock/raw/4090846/world-50m.json", function(error, world) {
    svg.insert("path", ".graticule")
    .datum(topojson.object(world, world.objects.land))
    .attr("class", "land")
    .attr("d", path);

    svg.insert("path", ".graticule")
    .datum(topojson.mesh(world, world.objects.countries, function(a, b) { return a.id !== b.id; }))
    .datum(topojson.mesh(world, world.objects.countries, function(a, b) { return a !== b; }))
    .attr("class", "boundary")
    .attr("d", path);
    });

    d3.select(self.frameElement).style("height", height + "px");

    </script>
  10. mbostock revised this gist Dec 24, 2012. 1 changed file with 4 additions and 3 deletions.
    7 changes: 4 additions & 3 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -18,7 +18,7 @@
    stroke-width: .5px;
    }

    .graticule:nth-child(2n) {
    .graticule :nth-child(2n) {
    stroke-dasharray: 2,2;
    }

    @@ -58,10 +58,11 @@
    .attr("class", "background")
    .attr("d", path);

    svg.selectAll(".graticule")
    svg.append("g")
    .attr("class", "graticule")
    .selectAll("path")
    .data(graticule.lines)
    .enter().append("path")
    .attr("class", "graticule")
    .attr("d", path);

    svg.append("path")
  11. mbostock revised this gist Dec 23, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as `d3.geo.azimuthalEquidistant` in [D3 3.0](https://github.com/mbostock/d3/wiki/3.0).
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as [d3.geo.azimuthalEquidistant](https://github.com/mbostock/d3/wiki/Geo-Projections#wiki-azimuthalEquidistant).
  12. mbostock revised this gist Dec 23, 2012. 2 changed files with 3 additions and 3 deletions.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as `d3.geo.azimuthalEquidistant` in [D3](http://d3js.org) 2.11.
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as `d3.geo.azimuthalEquidistant` in [D3 3.0](https://github.com/mbostock/d3/wiki/3.0).
    4 changes: 2 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -54,7 +54,7 @@
    .attr("height", height);

    svg.append("path")
    .datum(graticule.outline)
    .datum({type: "Sphere"})
    .attr("class", "background")
    .attr("d", path);

    @@ -65,7 +65,7 @@
    .attr("d", path);

    svg.append("path")
    .datum(graticule.outline)
    .datum({type: "Sphere"})
    .attr("class", "foreground")
    .attr("d", path);

  13. mbostock revised this gist Dec 7, 2012. 1 changed file with 11 additions and 15 deletions.
    26 changes: 11 additions & 15 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -35,21 +35,19 @@
    </style>
    <body>
    <script src="http://d3js.org/d3.v3.min.js"></script>
    <script src="http://d3js.org/topojson.v0.min.js"></script>
    <script>

    var width = 960,
    height = 500,
    ε = 1e-1;
    height = 500;

    var projection = d3.geo.azimuthalEquidistant()
    .translate([width / 2 - .5, height / 2 - .5])
    .precision(.1);
    .clipAngle(180 - 1e-3);

    var path = d3.geo.path()
    .projection(projection);

    var graticule = d3.geo.graticule()
    .extent([[-180 + ε, -90 + ε], [180 - ε, 90 - ε]]);
    var graticule = d3.geo.graticule();

    var svg = d3.select("body").append("svg")
    .attr("width", width)
    @@ -71,18 +69,16 @@
    .attr("class", "foreground")
    .attr("d", path);

    d3.json("/d/3682676/readme-boundaries.json", function(error, collection) {
    d3.json("/d/4090846/world-110m.json", function(error, world) {
    svg.insert("path", ".graticule")
    .datum(collection)
    .attr("class", "boundary")
    .datum(topojson.object(world, world.objects.land))
    .attr("class", "land")
    .attr("d", path);
    });

    d3.json("/d/3682676/readme-land.json", function(error, collection) {
    svg.insert("path", ".graticule,.boundary")
    .datum(collection)
    .attr("class", "land")
    svg.insert("path", ".graticule")
    .datum(topojson.mesh(world, world.objects.countries, function(a, b) { return a.id !== b.id; }))
    .attr("class", "boundary")
    .attr("d", path);
    });

    </script>
    </script>
  14. mbostock revised this gist Oct 26, 2012. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -71,14 +71,14 @@
    .attr("class", "foreground")
    .attr("d", path);

    d3.json("/d/3682676/readme-boundaries.json", function(collection) {
    d3.json("/d/3682676/readme-boundaries.json", function(error, collection) {
    svg.insert("path", ".graticule")
    .datum(collection)
    .attr("class", "boundary")
    .attr("d", path);
    });

    d3.json("/d/3682676/readme-land.json", function(collection) {
    d3.json("/d/3682676/readme-land.json", function(error, collection) {
    svg.insert("path", ".graticule,.boundary")
    .datum(collection)
    .attr("class", "land")
  15. mbostock revised this gist Oct 26, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion index.html
    Original file line number Diff line number Diff line change
    @@ -34,7 +34,7 @@

    </style>
    <body>
    <script src="https://raw.github.com/mbostock/d3/projection/d3.v2.min.js"></script>
    <script src="http://d3js.org/d3.v3.min.js"></script>
    <script>

    var width = 960,
  16. mbostock revised this gist Oct 12, 2012. 1 changed file with 0 additions and 0 deletions.
    Binary file added thumbnail.png
    Loading
    Sorry, something went wrong. Reload?
    Sorry, we cannot display this file.
    Sorry, this file is invalid so it cannot be displayed.
  17. mbostock revised this gist Oct 2, 2012. 1 changed file with 0 additions and 1 deletion.
    1 change: 0 additions & 1 deletion index.html
    Original file line number Diff line number Diff line change
    @@ -42,7 +42,6 @@
    ε = 1e-1;

    var projection = d3.geo.azimuthalEquidistant()
    .scale(100)
    .translate([width / 2 - .5, height / 2 - .5])
    .precision(.1);

  18. mbostock revised this gist Oct 2, 2012. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -42,6 +42,7 @@
    ε = 1e-1;

    var projection = d3.geo.azimuthalEquidistant()
    .scale(100)
    .translate([width / 2 - .5, height / 2 - .5])
    .precision(.1);

  19. mbostock revised this gist Oct 2, 2012. 1 changed file with 4 additions and 3 deletions.
    7 changes: 4 additions & 3 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -39,16 +39,17 @@

    var width = 960,
    height = 500,
    ε = 1e-3;
    ε = 1e-1;

    var projection = d3.geo.azimuthalEquidistant()
    .translate([width / 2 - .5, height / 2 - .5]);
    .translate([width / 2 - .5, height / 2 - .5])
    .precision(.1);

    var path = d3.geo.path()
    .projection(projection);

    var graticule = d3.geo.graticule()
    .extent([[-157.5, -90 + ε], [157.5, 90 - ε]]);
    .extent([[-180 + ε, -90 + ε], [180 - ε, 90 - ε]]);

    var svg = d3.select("body").append("svg")
    .attr("width", width)
  20. mbostock revised this gist Oct 2, 2012. 1 changed file with 3 additions and 2 deletions.
    5 changes: 3 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -38,7 +38,8 @@
    <script>

    var width = 960,
    height = 500;
    height = 500,
    ε = 1e-3;

    var projection = d3.geo.azimuthalEquidistant()
    .translate([width / 2 - .5, height / 2 - .5]);
    @@ -47,7 +48,7 @@
    .projection(projection);

    var graticule = d3.geo.graticule()
    .extent([[-157.5, -90 + 1e-3], [157.5, 90 - 1e-3]]);
    .extent([[-157.5, -90 + ε], [157.5, 90 - ε]]);

    var svg = d3.select("body").append("svg")
    .attr("width", width)
  21. mbostock revised this gist Sep 28, 2012. 2 changed files with 1 addition and 2 deletions.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as `d3.geo.azimuthalEquidistant` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as `d3.geo.azimuthalEquidistant` in [D3](http://d3js.org) 2.11.
    1 change: 0 additions & 1 deletion index.html
    Original file line number Diff line number Diff line change
    @@ -35,7 +35,6 @@
    </style>
    <body>
    <script src="https://raw.github.com/mbostock/d3/projection/d3.v2.min.js"></script>
    <script src="https://raw.github.com/d3/d3-plugins/projection/geo/projection/projection.js"></script>
    <script>

    var width = 960,
  22. mbostock revised this gist Sep 28, 2012. 1 changed file with 11 additions and 13 deletions.
    24 changes: 11 additions & 13 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -34,19 +34,21 @@

    </style>
    <body>
    <script src="http://d3js.org/d3.v2.min.js?2.10.1"></script>
    <script src="https://raw.github.com/d3/d3-plugins/master/geo/projection/projection.js"></script>
    <script src="https://raw.github.com/mbostock/d3/projection/d3.v2.min.js"></script>
    <script src="https://raw.github.com/d3/d3-plugins/projection/geo/projection/projection.js"></script>
    <script>

    var width = 960,
    height = 500;

    var projection = d3.geo.azimuthalEquidistant()
    .translate([width / 2 - .5, height / 2 - .5]);

    var path = d3.geo.path()
    .projection(d3.geo.azimuthalEquidistant()
    .translate([width / 2 - .5, height / 2 - .5]));
    .projection(projection);

    var graticule = d3.geo.graticule()
    .extent([[-157.5, -90], [157.5, 90]]);
    .extent([[-157.5, -90 + 1e-3], [157.5, 90 - 1e-3]]);

    var svg = d3.select("body").append("svg")
    .attr("width", width)
    @@ -69,20 +71,16 @@
    .attr("d", path);

    d3.json("/d/3682676/readme-boundaries.json", function(collection) {
    svg.insert("g", ".graticule")
    svg.insert("path", ".graticule")
    .datum(collection)
    .attr("class", "boundary")
    .selectAll("path")
    .data(collection.geometries)
    .enter().append("path")
    .attr("d", path);
    });

    d3.json("/d/3682676/readme-land.json", function(collection) {
    svg.insert("g", ".graticule,.boundary")
    svg.insert("path", ".graticule,.boundary")
    .datum(collection)
    .attr("class", "land")
    .selectAll("path")
    .data(collection.geometries)
    .enter().append("path")
    .attr("d", path);
    });

  23. mbostock revised this gist Sep 21, 2012. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion index.html
    Original file line number Diff line number Diff line change
    @@ -45,7 +45,8 @@
    .projection(d3.geo.azimuthalEquidistant()
    .translate([width / 2 - .5, height / 2 - .5]));

    var graticule = d3.geo.graticule();
    var graticule = d3.geo.graticule()
    .extent([[-157.5, -90], [157.5, 90]]);

    var svg = d3.select("body").append("svg")
    .attr("width", width)
  24. mbostock revised this gist Sep 20, 2012. 2 changed files with 2 additions and 2 deletions.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [Lambert azimuthal equal-area projection](http://en.wikipedia.org/wiki/Lambert_azimuthal_equal-area_projection) is available as `d3.geo.azimuthalEqualArea` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    The [azimuthal equidistant projection](http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection) is available as `d3.geo.azimuthalEquidistant` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    2 changes: 1 addition & 1 deletion index.html
    Original file line number Diff line number Diff line change
    @@ -42,7 +42,7 @@
    height = 500;

    var path = d3.geo.path()
    .projection(d3.geo.azimuthalEqualArea()
    .projection(d3.geo.azimuthalEquidistant()
    .translate([width / 2 - .5, height / 2 - .5]));

    var graticule = d3.geo.graticule();
  25. mbostock revised this gist Sep 20, 2012. 2 changed files with 3 additions and 3 deletions.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [Mollweide projection](http://en.wikipedia.org/wiki/Mollweide_projection) is available as `d3.geo.mollweide` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    The [Lambert azimuthal equal-area projection](http://en.wikipedia.org/wiki/Lambert_azimuthal_equal-area_projection) is available as `d3.geo.azimuthalEqualArea` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    4 changes: 2 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -34,15 +34,15 @@

    </style>
    <body>
    <script src="http://d3js.org/d3.v2.min.js"></script>
    <script src="http://d3js.org/d3.v2.min.js?2.10.1"></script>
    <script src="https://raw.github.com/d3/d3-plugins/master/geo/projection/projection.js"></script>
    <script>

    var width = 960,
    height = 500;

    var path = d3.geo.path()
    .projection(d3.geo.mollweide()
    .projection(d3.geo.azimuthalEqualArea()
    .translate([width / 2 - .5, height / 2 - .5]));

    var graticule = d3.geo.graticule();
  26. mbostock revised this gist Sep 16, 2012. 1 changed file with 3 additions and 3 deletions.
    6 changes: 3 additions & 3 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -71,7 +71,7 @@
    svg.insert("g", ".graticule")
    .attr("class", "boundary")
    .selectAll("path")
    .data(collection.features)
    .data(collection.geometries)
    .enter().append("path")
    .attr("d", path);
    });
    @@ -80,9 +80,9 @@
    svg.insert("g", ".graticule,.boundary")
    .attr("class", "land")
    .selectAll("path")
    .data(collection.features)
    .data(collection.geometries)
    .enter().append("path")
    .attr("d", path);
    });

    </script>
    </script>
  27. @jasondavies jasondavies revised this gist Sep 13, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [Mollweide projection](http://en.wikipedia.org/wiki/Mollweide_projection) is available as `d3.geo.mollweide` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/mollweide/geo/projection).
    The [Mollweide projection](http://en.wikipedia.org/wiki/Mollweide_projection) is available as `d3.geo.mollweide` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
  28. @jasondavies jasondavies revised this gist Sep 13, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion index.html
    Original file line number Diff line number Diff line change
    @@ -35,7 +35,7 @@
    </style>
    <body>
    <script src="http://d3js.org/d3.v2.min.js"></script>
    <script src="https://raw.github.com/d3/d3-plugins/mollweide/geo/projection/projection.js"></script>
    <script src="https://raw.github.com/d3/d3-plugins/master/geo/projection/projection.js"></script>
    <script>

    var width = 960,
  29. @jasondavies jasondavies revised this gist Sep 13, 2012. 2 changed files with 3 additions and 3 deletions.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [Aitoff projection](http://en.wikipedia.org/wiki/Aitoff_projection) is available as `d3.geo.aitoff` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    The [Mollweide projection](http://en.wikipedia.org/wiki/Mollweide_projection) is available as `d3.geo.mollweide` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/mollweide/geo/projection).
    4 changes: 2 additions & 2 deletions index.html
    Original file line number Diff line number Diff line change
    @@ -35,14 +35,14 @@
    </style>
    <body>
    <script src="http://d3js.org/d3.v2.min.js"></script>
    <script src="https://raw.github.com/d3/d3-plugins/master/geo/projection/projection.js"></script>
    <script src="https://raw.github.com/d3/d3-plugins/mollweide/geo/projection/projection.js"></script>
    <script>

    var width = 960,
    height = 500;

    var path = d3.geo.path()
    .projection(d3.geo.aitoff()
    .projection(d3.geo.mollweide()
    .translate([width / 2 - .5, height / 2 - .5]));

    var graticule = d3.geo.graticule();
  30. mbostock revised this gist Sep 13, 2012. 2 changed files with 2 additions and 2 deletions.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -1 +1 @@
    The [Cylindrical equal-area projection](http://en.wikipedia.org/wiki/Cylindrical_equal-area_projection) is available as `d3.geo.cylindricalEqualArea` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    The [Aitoff projection](http://en.wikipedia.org/wiki/Aitoff_projection) is available as `d3.geo.aitoff` in the [geo.projection D3 plugin](https://github.com/d3/d3-plugins/tree/master/geo/projection).
    2 changes: 1 addition & 1 deletion index.html
    Original file line number Diff line number Diff line change
    @@ -42,7 +42,7 @@
    height = 500;

    var path = d3.geo.path()
    .projection(d3.geo.cylindricalEqualArea()
    .projection(d3.geo.aitoff()
    .translate([width / 2 - .5, height / 2 - .5]));

    var graticule = d3.geo.graticule();