Perspective XY Chart DurationOn ms to Hours

Ignition Version 8.1.43

Hey there, my first post, and new user with the Ignition platform. I am using an XY Chart to display how long a bool (process state) has been true from a Canary Data historian. I have the historical data sources for each of the chart series properly set and aggregations are working. The issue is, the durations (y-axis) are being displayed in milliseconds and would like to have the durations displayed in hours. Please see the screenshot below....

I don't know where to begin on where to perform the appropriate math to convert from milliseconds to hours. Any help on where to do this in the chart configuration would be much appreciated. Thank you in advance for your help!

Regards,

Tim

I was able to find a script in another post and use it as a guide for my math. It is working but returning integers, I would like it to return floats in the value column. I have not determined the right approach for this yet. Any help on getting floats into the value field would be much appreciated. Thank You!


When you set convertedData to value, its going to use the types as they are. Use DatasetBuilder (ignition 7.9.5 API) to define your types instead.

Welcome to the forum, Timothy. Please see Wiki - how to post code on this forum. It helps when we want to edit your code into our answers.