-
Notifications
You must be signed in to change notification settings - Fork 12.1k
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
Added percent values in the tooltip and legend for stacked series #3362
Added percent values in the tooltip and legend for stacked series #3362
Conversation
Hi @torkelo , while working in this PR I've found something strange. Perhaps a "impossible condition" like that
in: If you agree I can include the fix in this PR. |
yes you are right about that condition |
Hi @torkelo , ready to merge. ;) |
Not sure there is enough demand for this option, maybe if there is many +1 votes :) |
seems like a very special case to show percent in the tooltip only. |
👍! |
+1 (really useful to see the distribution of things in the series without having to parse the values in your head) |
Hi @torkelo I think this case is not any special case. Consider memory metrics from collectd https://collectd.org/wiki/index.php/Plugin:Memory We have rendering from graphite as: Can you "in a fast view" say us the % of used memory, now? If you merge this you will see the % of used memory only with a look! |
+1 |
@toni-moreno I agree, sounds pretty useful for memory graphs. But still another option to maintain. With some unit tests and +1 votes it will very likely be merged :) |
Ok. @torkelo unit test added.. ...this few line of code are easy to maintain ( only one more variable and a loop to compute percent values).. nothing more!! |
+1 |
Super feature. I'm looking for this one a lot of time, and also an option to add the percent of total in the legend. |
Hi @shanielh I like your idea, but I need to understand in which time are you computing the % ? In the tooltip is clear that % depends on the time where mouse are placed, but legend values references a window time rather than a point.
Why are you computing % with total of series? perhaps could be more logical % on the average of each serie or perhaps the last value. ( I would prefer last value) Indeed you could compute different % values based on ( avg,max,min,total, last). What do you thing about @torkelo ? |
%avg will be the same as %total if the series have the same number of points. If they don't have the same number of points it might be logical to add %avg. The %current (last values) can be given by the tooltip when pointing to the last point. And I wasn't sure %min and %max would mean anything. In my case I really needed the %total because I have two graphs (or more) that splits the data to "buckets" and difference between the %totals points to success / failure. Think about graph of impressions and graph of conversions and two series of two algorithms that serves ads. So, if the first one has 40% impressions and 45% conversions, it might mean that it's better. |
You are right , I think is not possible stacked series with different number of points... in this case %total is good enough for us. I will merge and test tomorrow or Monday. Thank you very much to share this code with me ( and I hope with everybody if @torkelo, can accept it) |
1a77e19
to
c1fb20f
Compare
+1 |
@toni-moreno Thanks for merging. I hope it's going to get to the next version or to 2.6 👍 |
I not sure about this one. And right now it also included a new legend value which I think is a seperate feature. |
+1 |
+1 |
1 similar comment
+1 |
Sorry, closing this as it's drifted a bit from master. If you have time please reopen as a feature request so that people who have a need for this has a place to vote for it. |
With this PR you can see the percent of each series to the total stacked series by only move the mouse over the graph.
Useful to see in one view how big is a measurement and it's relative amount against other measurements and the total stacked
A new checkbox enable/disable this new feature.
You can disable this feature for individual series by only overriding the stack
This is the full editor