UI_Chart x Axis Label

HI,

i want to show Data from a database within a ui chart with x axis is the time y axis the value. When i use chart type bargraph i can set label of x-Axis by msg.topic. Using type line chart it seems to be not possible, the x axis label is always the current time.

Any idea how i can label x axis with time read from my database?

If you read all the data from a database you need to update the whole chart by providing the data as an array - the docs show the format you need to manipulate your data into depending on the type of chart you want.

Im not quite sure if u understood my problem correct.
in my database is stored time (e.g. 12:55:00) and value (e.g. 2000)
Using a bar chart every singel bar has the property of time(via msg.topic) and value(via msg-payload)
When i have a look at the properties i can set a min and max limit for y axis in bar chart (tahts fine for me) but there is no configuration for x axis. Using a line chart type there is a possibility to set the x axis to e.g. 1 day, but thats not what i want i would like to have the time of my database values as x axis label
See here the Bar Chart (with time of my database on x axis)
image

Time series is not something, the bar chart is meant for. But of course the choice is free if you can make the graph to talk in the way you can read it most easily.

There is example how to configure bar chart to 24 hours - one bar for every hour. Basics for your case remain same, create bar for every time mark you'll need to show.
Examine the example form this thread

If you need to present live (near live data with history) the new data points needed to be created and filled with data on every update where also too old data ponts will be removed

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.