Skip to content

Instantly share code, notes, and snippets.

@pbogden
pbogden / 5899e123023fd122@57.js
Last active November 15, 2019 10:22
Observable Leaflet
// https://observablehq.com/@pbogden/hello-leaflet-run-elsewhere@57
export default function define(runtime, observer) {
const main = runtime.module();
main.variable(observer()).define(["md"], function(md){return(
md`# Hello, Leaflet (run elsewhere)
A quick demo of [Leaflet](https://leafletjs.com/).
See below for instructions to download the code and run it in another web page,
where you can access the map and add a layer. If you get it to work, the map
@pbogden
pbogden / README.md
Created October 31, 2019 17:30
My Demo Gist

Hello world

@pbogden
pbogden / README.md
Last active February 15, 2019 22:08
Leaflet earthquakes
@pbogden
pbogden / README.md
Last active February 1, 2019 16:54
plot.ly scatterplot
@pbogden
pbogden / foo.js
Last active December 4, 2018 13:23
observable demo
x=42;
console.log('bar')
@pbogden
pbogden / README.md
Last active May 19, 2017 15:43
final - spring 2017

Here goes...

  1. Plot the counties in California
  2. Use another projection
  3. Use California state plane coordinates
  4. Instead of counties, plot the last week's worth of earthquakes
  5. Turn the earthquakes red
  6. Turn an earthquake yellow when you mouse over it
  7. Turn an earthquake back to red when you move your mouse away from it
  8. When mousing over an earthquake, indicate the "place" and "magnitude" with the tooltip
@pbogden
pbogden / README.md
Last active May 2, 2017 13:59
sprite