You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2022/06/07 12:20:42 UTC
[GitHub] [echarts] Shaq76 opened a new issue, #17179: [Feature] Support for 100% stacked charts
Shaq76 opened a new issue, #17179:
URL: https://github.com/apache/echarts/issues/17179
### What problem does this feature solve?
I am trying to emulate the functionality provided by Excel and echarts has no native support for 100% stacked charts.
I have tried to work around this by calculating the percentages myself but then you lose the original value tooltip.
There is an existing issue about this here:
https://github.com/apache/echarts/issues/8785
Apache superset has already implemented this feature, see here: (in the superset code it's called a 'contribution')
https://github.com/apache/superset/issues/13580
### What does the proposed API look like?
My suggestion is that you extend the 'stack' syntax to support something like this:
stack: { name: 'male', type: '100%' }
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
Re: [I] [Feature] Support for 100% stacked charts [echarts]
Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1963478728
Please checkout https://echarts.apache.org/examples/zh/editor.html?c=bar-stack-normalization and https://echarts.apache.org/examples/zh/editor.html?c=bar-stack-normalization-and-variation
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Ovilia commented on issue #17179: [Feature] Support for 100% stacked charts
Posted by GitBox <gi...@apache.org>.
Ovilia commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1149683094
You should probably save the sum to a variable that can be accessed by `valueFormatter`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Ovilia commented on issue #17179: [Feature] Support for 100% stacked charts
Posted by GitBox <gi...@apache.org>.
Ovilia commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1149398263
The advised way to do so is to calculate percentage as you said. The tooltip can set `formatter` or `valueFormatter` to calculate the original value. If you or anyone from the Apache Superset community wish to implement this in Apache ECharts, we would appreciate it very much. Maybe an option like `stackPercent: true` should be added.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
Re: [I] [Feature] Support for 100% stacked charts [echarts]
Posted by "108EAA0A (via GitHub)" <gi...@apache.org>.
108EAA0A commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1958941720
+1, Please implement this
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Shaq76 commented on issue #17179: [Feature] Support for 100% stacked charts
Posted by GitBox <gi...@apache.org>.
Shaq76 commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1149623360
Hi @Ovilia, I tried implementing the tooltip in valueFormatter but I'm not given the params object (which is available a few levels up the call stack) so the only information I know is the percentage value. If I use the tooltip formatter instead then I lose the nice default tooltip containing the series colour and other information. Thanks for your help :)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
Re: [I] [Feature] Support for 100% stacked charts [echarts]
Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia closed issue #17179: [Feature] Support for 100% stacked charts
URL: https://github.com/apache/echarts/issues/17179
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Shaq76 commented on issue #17179: [Feature] Support for 100% stacked charts
Posted by GitBox <gi...@apache.org>.
Shaq76 commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1162007337
Just a note that this looks similar in implementation to the following PR:
#17086
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Creatium commented on issue #17179: [Feature] Support for 100% stacked charts
Posted by GitBox <gi...@apache.org>.
Creatium commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1305640394
Hi. Any updates on this? I still see no way to make bar charts stack to 100%. Calculating values to "0.x" does nothing (or maybe I am doing it wrong).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] LeoDiep commented on issue #17179: [Feature] Support for 100% stacked charts
Posted by "LeoDiep (via GitHub)" <gi...@apache.org>.
LeoDiep commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1711044045
Hi. is this still updated
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
Re: [I] [Feature] Support for 100% stacked charts [echarts]
Posted by "Shaq76 (via GitHub)" <gi...@apache.org>.
Shaq76 commented on issue #17179:
URL: https://github.com/apache/echarts/issues/17179#issuecomment-1963791359
Hi, I have looked at the two examples and these do work around part of the problem, but not fully.
By transforming the incoming data in to percentages we can no longer get access to the original values.
The result is that the tooltip can only show the percentage value, see below.
![image](https://github.com/apache/echarts/assets/19664605/f3e3f001-7a16-4e2a-b933-b83b4596cb53)
So the problem remains: I want to plot 100% stacked while keeping the source data as the original value?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org