Published
Edited
Sep 22, 2018
2 forks
3 stars
Insert cell
Insert cell
Insert cell
Insert cell
picasso.chart({
element: document.querySelector('#container'),
data,
settings: {
scales: {
c: {
data: { extract: { field: 'Year' } }, type: 'color'
}
},
components: [{
type: 'legend-cat',
scale: 'c'
}, {
key: 'p',
type: 'pie',
data: {
extract: {
field: 'Year',
props: {
num: { field: 'Sales' }
}
}
},
settings: {
padAngle: 0.01,
slice: {
cornerRadius: 4,
innerRadius: 0.4,
arc: { ref: 'num' },
fill: { scale: 'c' },
strokeWidth: 1,
stroke: 'rgba(255, 255, 255, 0.5)'
}
}
}]
}
})
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