I recreated the two ways I tested, but didn't get to work:


First I set data to the first dataset and added for each label/series an extra 
dataset using a tranformation for filtering entries by "operation" attribute:

https://codesandbox.io/s/github/dneukamm-netze-odr/echarts-scatter-test/tree/json-dataset?file=/src/App.vue

Each series ist mapped with dataGroupId. All data is displayed but don't get 
split up for each series.



Why does the data entries not get split up? The filter transformation seem to 
work and the reference from one series to the (filtered) dataset, too.



The second try was to divide data for each series and setting data there.

https://codesandbox.io/s/github/dneukamm-netze-odr/echarts-scatter-test/tree/json-series-data?file=/src/App.vue

In this example the chart will not even get drawn!

Can you tell me, what's the problem here?



Are there any further examples to show how to deal with JSON data? How to split 
it up, how to use dimensions with it, how to use it with encode ...

JSON or "Row based key-value format (object array), where the keys indicate 
dimension names." Is mentioned in the docs only as short paragraph, it is 
missing some "depth".

Have you any additional examples or further infos how to deal with JSON data?

On 2022/07/21 09:29:53 "Neukamm, Dominik" wrote:

> Hey,

>

> I'm having problems with implementing a scatter chart with the following data 
> structure:

>

> [

>     {

>         "callTs": 1655799367000,

>         "operation": "Operation1",

>         "sec": 0,

>         "message": "Message 1",

>         "info": "Additional info for tooltip",

>     },

>     {

>         "callTs": 1655799384000,

>         "operation": " Operation2",

>         "sec": 96,

>         "message": "Message 2",

>         "info": "Additional info for tooltip",

>     },

>     {

>         "callTs": 1655803891000,

>         "operation": " Operation3",

>         "sec": 0,

>         "message": "Message 3",

>         "info": "Additional info for tooltip",

>     },

>     {

>         "callTs": 1655803934000,

>         "operation": " Operation3",

>         "sec": 1,

>         "message": "Message 4",

>         "info": "Additional info for tooltip",

>     }

> ]

>

> How can I group them as individual series by the "operation" value? Is it 
> efficient to set data as first dataset and create for each series a new 
> dataset with a transform filter?

> And how do I bind "callTS" to the x axis and "sec" to the y axis? Do I need 
> to specify the dimensions or should this work with setting the encode?

>

>

> Thanks for your help

> Dominik

>

>

Reply via email to