Published
Edited
May 13, 2020
2 stars
Insert cell
Insert cell
Insert cell
html`<div style='column-count: 6; font-size: 3px;'>
${data.map(d => wrapper(d.sentence, d.polarity))}
</div>`
Insert cell
wrapper = (s, p) => `<span style='background: ${ colorScale(p) }'>${s}</span>`
Insert cell
colorScale = d3.scaleSequential(d3.interpolateViridis).domain([-1, 1])
Insert cell
Insert cell
Insert cell
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