echarts [Feature] 给平行坐标系的各个坐标轴设置的选择范围

3pmvbmvn  于 5个月前  发布在  Echarts
关注(0)|答案(5)|浏览(58)

What problem does this feature solve?

  1. 通过其他模块已知的过滤参数来展示正确平行坐标系。如图:

What does the proposed API look like?

  1. 初始化时:
parallelAxis: [
    { dim: 0, name: '语文', selected:[60, 100] },
    { dim: 1, name: '数学', selected:[60, 100] },
    { dim: 2, name: '等级', type: 'category', selected:['优秀','及格'] },
]
  1. 编辑修改单个坐标轴范围:
const option = echart.getOption()
option.parallelAxis[1].selected = [80, 100]
echart.setOption(option, true)
new9mtju

new9mtju1#

@jarvis000000 It seems you are not using English, I've helped translate the content automatically. To make your issue understood by more people and get helped, we'd like to suggest using English next time. 🤗
TRANSLATED

TITLE

[Feature] The selection range set for each axis of a parallel coordinate system

BODY

What problem does this feature solve?

  1. Display the correct parallel coordinate system through the filter parameters known by other modules. As shown in the picture:

What does the proposed API look like?

  1. During initialization:
parallelAxis: [
    { dim: 0, name: 'Chinese', selected: [60, 100] },
    { dim: 1, name: 'math', selected:[60, 100] },
    { dim: 2, name: 'grade' , selected:['excellent','pass'] },
]
  1. Edit and modify the range of a single coordinate axis:
const option = echart. getOption()
option.parallelAxis[1].selected = [80, 100]
echart. setOption(option, true)
ikfrs5lh

ikfrs5lh2#

Ok, each axis predefined (manual) selection range will filter some lines. For example:

parallelAxis: [
    { dim: 0, name: '语文', selected:[60, 100] },    // lines A,B,C
    { dim: 1, name: '数学', selected:[60, 100] },    // lines B,C,D  
    { dim: 2, name: '等级', type: 'category', selected:['优秀','及格'] },   // lines A,E,F
]

I don't think such example is going to be a pretty picture or make any sense.
There is no guarantee that the same lines will pass through all manual selections.

dwthyt8l

dwthyt8l3#

“I don't think such example is going to be a pretty picture or make any sense.” Yes I agree. But some times users just do such stupid operations. Some times if the selections which get from users make no line can pass all selections, users can still get the answer they want from this picture.

xyhw6mcr

xyhw6mcr4#

ok, then just filter by all axis ranges and show the entire subset. Why filter at the visualization level? Much easier to do in advance when building the data for the new option.

hrirmatl

hrirmatl5#

As we can see, all the data becomes lines at the visualization level. Even though some lines can not pass the filters,but they are still in the picture with downplay state, we don't want to abandon them. We can expand selections areas easily and purposefully to find a line pass the filters. As you know, set filters usually by form in other modules. We want to know not only which lines can pass the filters but also the range of each fitler and lines which can not pass the filters from parallel. Only highlight the passed lines will lose some informations(the range of each filter).

相关问题