Public
Edited
Feb 21, 2024
1 fork
8 stars
Kerkovits projectionA map of AfricaCupola ProjectionClipping spherical polygonsA conformal AiroceanFill with strokeMarkley’s tetrahedral mapSynchronized projectionsSatellite GLSLVan Der Grinten IV GLSLVan Der Grinten III GLSLVan Der Grinten II GLSLWinkel Tripel GLSLLee Modified Stereographic GLSLMiller Oblated Stereographic GLSLModified Stereographic GS48 GLSLModified Stereographic GS50 GLSLFoucaut GLSLLagrange GLSLKavrayskiy VII GLSLEisenlohr GLSLEckert VI GLSLEckert V GLSLEckert IV GLSLEckert III GLSLEckert II GLSLEckert I GLSLBertin1953 GLSLRobinson GLSLMiller GLSLRectangular Polyconic GLSLPatterson GLSLPolyconic GLSLLoximuthal GLSLCylindrical Stereographic GLSLCylindrical Equal-Area GLSLTransverse Fahey GLSLFahey GLSLCollignon GLSLBromley GLSLBottomley GLSLHammer GLSLBonne GLSLBoggs GLSLBerghaus GLSLBaker Transverse GLSLBaker GLSLAugust GLSLAiry GLSLAitoff GLSLArmadillo GLSLLarrivée GLSLCylindrical Equal-Area GLSLAzimuthal Equidistant GLSLLittrow GLSLVan Der Grinten GLSLEquirectangular GLSLConic Conformal GLSLConic Equidistant GLSLAlbers GLSLConic Equal-Area GLSLEqual Earth GLSLTimes GLSLWagner IV GLSLWagner VI GLSLWagner VII GLSLWiechel GLSLAtlantis GLSLMollweide GLSLMercator GLSLTransverse Mercator GLSLCordiform GLSLWebMercator to globeVersor zooming for Three.jsAzimuthal Equal-Area GLSLBriesemeister GLSLRectilinear GLSLPhytoplanktonDanseiji projectionsTransverse MollweideThe 2D approximate Newton-Raphson methodInverting Lee’s Tetrahedral projectionAmerican PolyconicThe complex logarithm projectionRaster projection with GPU.js
H3 hexagons & geoContours
Modified Stereographic ProjectionsFisheye Conformal Map (Cox)Fisheye Conformal MapFisheye Conformal Map (Tetrahedral)Reproject elevation tiles — worldTransverse projectionsThe Imago projectionD3 ProjectionsImago Projection Distorsion AnalysisEPSG:5530Imago tilingCordiform map projections 💛💗💖MultiPolygon clippingThe Nicolosi Globular ProjectionFisheye GlobeHerbert Bayer’s Pacific OceanThe Behrmann projectionOronce Finé’s triangle projectionDa Vinci’s octant projectionThe Lotus projection (1958)The Voronoi projectionUsing proj4js with D3 and PlotMurphey Butterfly ProjectionEquateur & tropiquesVega projectionsMercator projection of a Mercator globeThe truth about the Mercator projectionOcean-centric Mollweide projectionBuckminster Fuller’s triangle transformationExperimental two world projectionsTobler’s hyperelliptical projection (1973)Jacques Bertin’s projection (1953)A map without Antarctica (Bertin1953 projection)Square Root Azimuthal projectionThe Log-Azimuthal projectionPeirce Quincuncial Projection, centered on the South PoleTranslucent Earth (Satellite projection)Lee’s conformal projection in a tetrahedronAirocean projectionCubic projectionsCox conformal projection in a triangleIcosahedral projectionsDodecahedral projectionThe Cahill-Keyes projection (1975)Polyhedral projections with d3-geo-polygonWagner customizable projectionParametrized Equal Earth ProjectionThe Hufnagel projection systemTissot's indicatrixAn equal-area projection for the cubic EarthBase map
Also listed in…
Geo
Tricontours
Insert cell
Insert cell
chart()
Insert cell
h3 = require("h3-js@3") // needs an update for v4, the API has changed
Insert cell
hexworld = level => ({
type: "FeatureCollection",
features: h3.getRes0Indexes()
.map(i => h3.h3ToChildren(i, level))
.flat()
.map(d => ({
type: "Feature",
properties: { id: d, pentagon: h3.h3IsPentagon(d) },
geometry: {
type: "Polygon",
coordinates: [h3.h3ToGeoBoundary(d, true).reverse()]
}
}))
})
Insert cell
hexagons = hexworld(1) // level 2 is fine, level 3 a bit slow… level 4 oh my
Insert cell
color = d3.scaleSequential(d3.interpolateCool)
Insert cell
projection = d3.geoAirocean()
.angle(-150)
.fitExtent([[2, 2], [width - 2, height - 2]], { type: "Sphere" })
Insert cell
contours = d3.geoContour().value(() => Math.random())(
hexagons.features.map(d3.geoCentroid)
)
Insert cell
function chart() {
const context = DOM.context2d(width, height),
path = d3.geoPath(projection).context(context);

context.beginPath();
path({ type: "Sphere" });
context.fillStyle = color(0);
context.fill();
context.lineWidth = 3;
context.stroke();
context.clip();
context.lineWidth = 0.5;

for (const c of contours) {
context.beginPath();
path(c);
context.strokeStyle = context.fillStyle = color(c.value);
context.fill();
context.stroke();
}

context.beginPath();
context.fillStyle = "orange";
for (const penta of hexagons.features.filter(d => d.properties.pentagon))
path(penta);
context.fill();

context.strokeStyle = "#fff";
context.beginPath();
path(land);
path(hexagons);
context.lineWidth = 0.5;
context.stroke();

context.strokeStyle = "black";
context.beginPath();
path(land);
context.lineWidth = 1.5;
context.stroke();

return context.canvas;
}
Insert cell
d3 = require("d3@7", "d3-geo-voronoi@2", "d3-geo-polygon@1")
Insert cell
land = {
const world = await fetch(
"https://cdn.jsdelivr.net/npm/visionscarto-world-atlas@0.1.0/world/110m.json"
).then((d) => d.json());
return topojson.feature(world, world.objects.countries);
}
Insert cell
height = width * 2.1
Insert cell

One platform to build and deploy the best data apps

Experiment and prototype by building visualizations in live JavaScript notebooks. Collaborate with your team and decide which concepts to build out.
Use Observable Framework to build data apps locally. Use data loaders to build in any language or library, including Python, SQL, and R.
Seamlessly deploy to Observable. Test before you ship, use automatic deploy-on-commit, and ensure your projects are always up-to-date.
Learn more