Control visualize function for kibana line chart

My index has three Field: category, value, time.

Data record format in elasticsearch liked the following:

Record 1 - category: x1, value: 5, time: Jan 9, 2020 @ 13:28:00.000
Record 2 - category: x2, value: 6, time: Jan 9, 2020 @ 13:28:00.000
Record 3 - category: x3, value: 7, time: Jan 9, 2020 @ 13:28:00.000
Record 4 - category: y, value: 0, time: Jan 9, 2020 @ 13:28:00.000
Record 5 - category: x1, value: 2, time: Jan 9, 2020 @ 13:29:01.000
Record 6 - category: x2, value: 3, time: Jan 9, 2020 @ 13:29:01.000
Record 7 - category: x3, value: 4, time: Jan 9, 2020 @ 13:29:01.000
Record 8 - category: y, value: 1, time: Jan 9, 2020 @ 13:29:01.000
...

My category field contains four value types: x1, x2, x3, y and each type will be inserted to index every second with the same timestamp.


My Goal: Can the control visualize function support to choose any of two value types (eg. x1,x3) of category field to plot double y-axis and timestamp as the x-axis.


I have referred the kibana example data - [eCommerce], however, the control function used by this example seems like "Select two fields for each record" and then filter the data to plot.

In my case, It's not a good idea to create the field - filter which contains the value: x1-x2, x1-x3, x1-y, ... x3-y and insert multiple the same data record only with difference value of field - filter. It will contain lots of useless data in es only for filter function.

I am not sure that the same function can be properly used in my scenario or not? Or should I change my insert data format to achieve my scenario?


Also, does kibana have functions similar to subplot liked the following in one visualize chart?

I think your best bet here is to use the Split Chart feature of the Line Chart visualization. You can split by Terms of Category, which will then show 4 charts. By adding a filter such as Category: "x1" OR Category: "x2" to either the visualization or dashboard, you will get the side-by-side chart you were looking for.

It seems that you provide a good way for me.

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