helgasoft commented on issue #18060: URL: https://github.com/apache/echarts/issues/18060#issuecomment-1352020427
Agree - _node length should be proportional to its value_. But there is a **second rule** in sankey(flow) diagrams - sums of quantities at each level should be equal. Sum at start should be equal to sum at end, otherwise the chart does not make sense. A good example of **incorrect** chart is the _Expected Behavior_ chart sample above (1.815 = 1.641 + 3.456 ?!) It turns out the **correct** equation is NetRevenue + Oper.Expenses = Oper.Loss (1.815 + 1.641 = 3.456). And here is how it looks in ECharts: [Demo Code](https://echarts.apache.org/examples/en/editor.html?c=sankey-simple&code=MYewdgzgLgBAZiEBeGAKADgQwE4EoZIB8MA3gLABQMM2AplAK7ZgxbYB0YmAtrTANQwA5AC5hAmJWrSMOTj1rtoOKBADqASygALVEIDy6WtiH4A_DAC0bdgDdMAGwZ8xN-09q4A3JQC-lEHQoDXACUikYKEQHYPQxcippJKhsDQBzNOMxIS1abiEAGgik6hT0zOx9MGzuEAYIPJBbWkLi6V8ixIbU2gh4tqgATyNsiEwwAGtaQdbE6jz0bUwIDT7SeBBgeuzMABMAK0xgWjBgGZgOtodMACNaB3iN7G5MKCgsjZALzqSGh1pgO9dgBZEC7WhiFLOH7SXavTBiADa1Da1ASJWkXF42UMxnYAFEAB5GSC9WYY6juZxiADM7AALPSAKwANhhGNy3AAykN_v05hTQA4QNhsjcPEJUe0pZcBWipdQsRDhAA5egwABKtGaYGc5IpVOVAEZ2AAOI3skqcnmDPnhOUlIUi7JpOgnSUO6j-B2yjHoilKnFGDgAGRAEAg-oxhrEJpZ9MtSWtvOV_opMCdouEdF2HvT3oxvukAF1LQ4NJM1oipWmShA6thjtk1bAtTq9YnpFAcJkoEG8USSQ1I53KY5qSbzaOYOWwLQbXbaxjMy63WAoxTAkctIMxAAGBkKi4yztL6T1phN4S40PhkdH7vYXv9jiDk7DjdJGMwOMJo-z-cU35dNqBXbNaFzadqC3YAd33Q9PWPH1LWLCJfF8LwgA)  -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
