plot.ts aktualisiert

main
Alexander Kimmig 2025-06-03 00:17:39 +02:00
parent 21f193263c
commit 7a85fd29d1
1 changed files with 1 additions and 1 deletions

View File

@ -11,5 +11,5 @@ export const plot = (data) => {
export const plotxy = (xmin, xmax, step, y) => {
const x = Array.from({length: (xmax - xmin)/step}, (_, i) => i * step + xmin)
const data = x.map(x => ({x, y: y(x)}))
return Plot.line(data, {x: "x", y: "y"}).plot({y: {grid: true}, document})
return Plot.line(data, {x: "x", y: "y"}).plot({y: {grid: true}, x: {grid: true}, document})
}