I have a line graph chart in my dashboard, where X is a timestamp series.
It display 4 graph lines with 800 datapoints.
var j=0;
var i=0;
var dataarray = [[],[],[],[]];
for (i = 800; i >= 0; i--) {
dataarray[0][i] = {"x":global.get("market.data["+j+"].timestamp"),"y":global.get("market.data["+j+"].close")};
dataarray[1][i] = {"x":global.get("market.data["+j+"].timestamp"),"y":global.get("market.data["+j+"].MFA_short")};
dataarray[2][i] = {"x":global.get("market.data["+j+"].timestamp"),"y":global.get("market.data["+j+"].MFA_long")};
dataarray[3][i] = {"x":global.get("market.data["+j+"].timestamp"),"y":global.get("market.data["+j+"].MFA_40")};
j++;
}
var chart = [{
"series":["close","MFA_short","MFA_long", "MFA_40"],
"data":dataarray,
"labels":[""]
}];
msg.payload = chart;
msg.topic = "test";
return msg;
I also have an array of 40 additional timestamps as a second set of data with no corresponding Y values:
[1632552397900,1632551497602,1632540996402, ...]
Is it possible to mark these timestamp positions on the existing graph with a bullet or vertical line or something else entirely, that mark those moments visually?