Public
Edited
Feb 3, 2023
17 forks
Importers
13 stars
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
{
// this line is a little bit of Observable magic to make sure that every time
// our filter cells update, we use the existing SVG element instead of trashing it and creating a new one
// if you're working in your index.html, you'd create your svg element and select it as we did before
const svg = this || html`<svg width=${width} height=${width / 2}></svg>`
mutable graph = calculateGraph(graph)
// ✨ OUR CODE HERE
// invalidation.then(() => simulation.stop())
return svg
}
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
import {
movies, slide, slide_style,
svgHeight, scrollSVG, textWidth,
topGenres, rated,
} from '@sxywu/workshop-utility-functions'
Insert cell
import {calculateData} from '2683357905679f61'
Insert cell
topGenresOther = _.union(topGenres, ['Other'])
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
import {checkbox} from "@jashkenas/inputs"
Insert cell
slide_style
Insert cell
d3 = require('d3')
Insert cell
_ = require('lodash')
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more