Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] 透视表自定义列头对齐s2的功能 #1644

Closed
xiaochong444 opened this issue May 7, 2024 · 2 comments · Fixed by #1673
Closed

[Feature] 透视表自定义列头对齐s2的功能 #1644

xiaochong444 opened this issue May 7, 2024 · 2 comments · Fixed by #1673
Assignees

Comments

@xiaochong444
Copy link

What problem does this feature solve?

在数据透视分析的过程中有可能透视表只有行和值,当值的字段又非常多的时候,希望通过自定义列头的形式对指标进行分组。
类似如下的一种bi分析形式,实际上列上的表头都是虚拟的,并没有维度字段去绑定,层级数也不确定。使用s2的自定义列头很容易做到,但是用vtable现在无法实现
image

What does the proposed API look like?

功能上和下面s2的例子一样,透视表绑定行和值,列头用自定义树生成,由于整个列都是自定义的,所以列的小计总计问题无须考虑,由用户自己负责
https://s2.antv.antgroup.com/examples/layout/custom-header-group/#custom-pivot-col-header

@fangsmile fangsmile self-assigned this May 7, 2024
@fangsmile
Copy link
Contributor

数据records那就必须每一列分别对应一个指标字段了吧
image
@xiaochong444

@xiaochong444
Copy link
Author

xiaochong444 commented May 8, 2024

@fangsmile
是的,列的叶子节点和指标一一对应,s2也是这样实现的,父节点field就是个虚拟的唯一标识,叶子节点的field对应指标
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants