Line Chart - Show only with filter
I am building a line chart that shows value over time. However, there are over items. Is there a way to setup the line chart to only show when I filter on one item?
Example:
Line chart is blank > then I select one item from my drop down or filter > then the line chart will show it's value over time.
HQ_Dev_Prod
Posted 1 year ago·Last reply 1 year ago
6 comments
harikm007
·1 year agoHi HQ_Dev_Prod ,
You can achieve this by using a widget script. Add the script below to your line chart and ensure you update the variable 'filterTitle' with the name of your filter.
This script will also display the message "Select one filter item" if no items or more than one item are selected. For further customization of the message and image, check out this post: https://www.binextlevel.com/post/custom-no-result-message
Result:
Feel free to reach out if you have any questions!
-Hari
https://www.binextlevel.com/
HQ_Dev_Prod
OP1 year agoThank you Hari!
Is it possible to set this process up so that if I select an item from a pie chart to filter the data, the line chart populates? Such that I don't have to go to the filters pan, but rather I can drill down to the line chart detail for a specific item from a pie chart?
harikm007
·1 year agoIf I understand your question correctly, you want the line chart to update when you click on a slice of the pie chart, right? If that's the case, clicking on a slice of the pie chart automatically applies a filter to the dashboard, so the same script should work here. Please refer to the GIF below.
Does that address your question?
HQ_Dev_Prod
OP1 year agoYes, this is correct. This is what I'm looking to achieve.
HQ_Dev_Prod
OP1 year agoLooks like your solution worked!
However, by adding the script, I am no longer able to select a dimension in the pie chart to slice the data as a filter.
HQ_Dev_Prod
OP1 year agoNevermind, I was making a basic error and it's now solved. Thank you!