apache / superset

Apache Superset is a Data Visualization and Data Exploration Platform
https://superset.apache.org/
Apache License 2.0
61.99k stars 13.59k forks source link

Proposal for Waterfall chart improvement in handling first and last subtotals (do not add SIP number) #30320

Open code-luac opened 1 week ago

code-luac commented 1 week ago

Please make sure you are familiar with the SIP process documented here. The SIP will be numbered by a committer upon acceptance.

[SIP] Proposal for Waterfall chart improvement in handling first and last subtotals</h2> <h3>Motivation</h3> <ol> <li>Today, the implementation assumes that the first value in the series is zero. However, this is not always the case. For example, I want to review the evolution of my task backlog over time (opened vs. closed tickets and subtotals with a weekly time grain). When filtering for a particular time window (not from the beginning of time), I want to see how many open tickets there were at the beginning of this period.</li> <li>Today, the last bar in the chart displays the subtotal. I want to control whether this last subtotal appears or not.</li> </ol> <p>This brings the waterfall chart to par with Google Sheets and MS Excel.</p> <h3>Proposed Change</h3> <p>I used the following screenshot from Google Sheets to serve as my wireframe. Requirements for the Waterfall Chart settings (see the markup in the screenshot):</p> <ol> <li>A new checkbox "Use first value as subtotal" - when checked, render the first bar in the chart as a subtotal (gray) using the first value in the series.</li> <li>A new checkbox "Add subtotal after last value in series" - when checked, render the last bar in the chart as a subtotal (gray) representing the series' total. <img referrerpolicy="no-referrer" src="https://github.com/user-attachments/assets/6eb681e3-5808-4b64-bf65-f8bf43580409" alt="image" /></li> </ol> <h3>New or Changed Public Interfaces</h3> <p>Describe any new additions to the model, views or <code>REST</code> endpoints: Change the chart settings API to reflect the 2 new settings checkboxes.</p> <p>Describe any changes to existing visualizations, dashboards and React components. Describe changes that affect the Superset CLI and how Superset is deployed: See proposed change section above.</p> <h3>New dependencies</h3> <p>None</p> <h3>Migration Plan and Compatibility</h3> <p>None</p> <h3>Rejected Alternatives</h3> <p>None</p> </div> </div> <div class="comment"> <div class="user"> <a rel="noreferrer nofollow" target="_blank" href="https://github.com/michael-s-molina"><img src="https://avatars.githubusercontent.com/u/70410625?v=4" />michael-s-molina</a> commented <strong> 1 day ago</strong> </div> <div class="markdown-body"> <p>Hi @code-luac. I believe this is a valid feature request that does not require a SIP given its scope. I don't have the bandwidth to implement this now as I'm focused on stabilizing 4.1 but I hope someone from the community can provide such feature as it would be valuable.</p> </div> </div> <div class="comment"> <div class="user"> <a rel="noreferrer nofollow" target="_blank" href="https://github.com/rusackas"><img src="https://avatars.githubusercontent.com/u/812905?v=4" />rusackas</a> commented <strong> 14 hours ago</strong> </div> <div class="markdown-body"> <p>Agreed with Michael. We'd welcome a PR with these changes. If you don't want to consider it a SIP, I think there are two potential moves for this issue: 1) We can move it to an Ideas discussion thread if you want more discussion/feedback/help with it 2) We can leave it here if you have more immediate plans to open a PR that closes it. Let us know which seems appropriate, and thanks for the input/ideas!</p> </div> </div> <div class="page-bar-simple"> </div> <div class="footer"> <ul class="body"> <li>© <script> document.write(new Date().getFullYear()) </script> Githubissues.</li> <li>Githubissues is a development platform for aggregating issues.</li> </ul> </div> <script src="https://cdn.jsdelivr.net/npm/jquery@3.5.1/dist/jquery.min.js"></script> <script src="/githubissues/assets/js.js"></script> <script src="/githubissues/assets/markdown.js"></script> <script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.4.0/build/highlight.min.js"></script> <script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.4.0/build/languages/go.min.js"></script> <script> hljs.highlightAll(); </script> </body> </html>