Graph
canvas.graphBlock elementGraph
A graph pane on the scene's canvas. Holds marks (scatter, curve, line, shapes…) plus the fit element; parameters are native to the surface (the fit degree and free expression parameters get controls in the pane footer). The x/y domains are animatable with !cue.to keyframes.
Attributes
x-domain
intervaly-domain
intervalinteractive
booleanDefaultfalse
show-background
booleanDefaulttrue
grid-style
Defaultlines
continue
referenceAllowed content
Allowed in
Examples
canvas.graph#fit-graph{
scatter(points: (1, 2.0), (2, 2.4), (3, 3.1), (4, 4.8); colour: grey)
fit(model: polynomial; degree: 1 to 4; default: 1; colour: teal)
cue{
residuals(of: fit; colour: orange)
}(
in: 1
)
}(
x-axis-label: x
y-axis-label: y
)Notes
- A pane's own id is written on the node — `canvas.graph#projectile{…}` — and `continue:` points at it with `#projectile`.