viewof chart = Plot.plot({
title: "Associating chart title with graph",
caption: "Associated legend text with graph.",
y: {grid: true},
marks: [
Plot.rectY(table, {y: form.y_dimension, x: "date", fill: form.fill_dimension, sort: form.fill_dimension, tip: "x"}),
Plot.rectY(table, Plot.pointer({y: form.y_dimension, x: "date", stroke: "#E5006E", fill: "#E5006E", fillOpacity: 0.5, sort: form.fill_dimension})),
Plot.ruleY([0])
],
color: {legend: true},
marginLeft : 60
})