Public
Edited
May 3, 2023
Insert cell
Insert cell
Plot.plot({
x:{domain:[0,70]},
y:{domain:[0,30]},
marks:[
Plot.ruleX([0]),
Plot.ruleY([0]),
Plot.dot(X,{x:X,y:Y}),
Plot.line([
[0,0],
[70,slope*70]
],{stroke:"red"})
]
})
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
regression = new Regression(X,Y,50,.0001)
Insert cell
slope = regression.fit()
Insert cell
Insert cell
Type JavaScript, then Shift-Enter. Ctrl-space for more options. Arrow ↑/↓ to switch modes.

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