Generated value vaadin chart

Hi’

I’m currently trying to graph changes in a systems state. For an example the value 8002 may be “Unstable”, the value 7128 may be “Running” and so on. I would really like to graph these values, so that I over time can see on a line graph how the system behaves.

But I can’t seem to find a way to do this. I thought about using plot bands, but the values are too different, (fx 8001, 8002, 8004, 8008, 8016, 8032, 8064 and 8128).

Hope anyone can help me :slight_smile:

Best regards
Ben

Does the criteria for a state change over time? Are the plot bands a bad option because the areas of the bands are too different from each other or why that doesn’t work for you?

Hi Johannes

No, the critiria is the same. 9001 will for example always be “35mhz broad”, but if I was to use the plot band, wouldn’t it mean that the difference between the numbers (1,2,4,8,16,32,64,128) would make the 128 plotband enourmous compared to 1 and 2? :slight_smile:

How about if you set the y axis logarithmic.

chart.getConfiguration().getyAxis().setType(AxisType.LOGARITHMIC);

Hi’

Didn’t help much, since it could change between 1k and 9k too. I ended up using the “resouce” example from the demo :slight_smile:

I’m glad you found a solution. Could you share a screenshot of the resulting chart? I’m interested.

Hi,

Yea. I thought so too. Though after a couple of tests I found out that the bare couldn’t be split in to multiple parts, but could only have a single low and a single high which then would result in the attached screenshot (For some reason it calls both threadpair on, but the “top” threadpair 1 should be at threadpair 4, and the buttom to threadpair 1). Do you have any idea how to split the graph up? In case threadpair x uses mode a from 0-800 meters, mode b from 800-1200 meters and back to a from 1200-2000 meters?

This is surprisingly difficult to graph, wow. :stuck_out_tongue:
25826.png

I’m having a bit of a hard time understanding exactly how you would like the graph to look like. Could you for example draw it out first on paper or paint or something and show that? Then it would be easier to help on how you would get Vaadin Charts to draw that.

Hi Jens

I’ve tried sketching an example in paint, please see the attatchment.

The data might be:

Threadpair 1

0m: 17A
50m: 17A
​100m: 17A
​150m: 17A
​200m: 8B
​250m: 8B
​300m: 8B
​350m: 17A
400m: 17A
450m: 17A
500m: 8B
550m: 8B

I hope you see what I’m looking for :slight_smile:

Thanks!
Ben​

25906.png