Cards, Dashboards, Stories

Cards, Dashboards, Stories

Beast mode that looks at filters?

Afternoon, I have some metrics that I would like to change automatically when a filter is selected and wondering if there is a way to do that through a beast mode (or any other way)?

For example I have lanes A to B and also A to C and I have one card that I filter on the destination B and C to see the percentage of shipments that have made it within our time window. A to B is 4 days or less and A to C is 12 days or less. I want the card to show the percentage of shipments that made it within 4 or 12 days depending which destination the filter is set to.

Is that even possible to do based on a filter?

Also, cant split into multiple cards as there as so many destination pairings that it would be way to many cards.

Welcome!

It looks like you're new here. Members get access to exclusive content, events, rewards, and more. Sign in or register to get started.
Sign In

Best Answer

  • Answer ✓

    As bryce mentioned variables are a great way to do this if you want the axis values to change based on a filter. You could, however just group data together with a beastmode and then allow users to switch between that grouping as long as the aggregation remains constant (Sum, average, max, etc…) which it sounds like it is: % of shipments.

    Example Beastmode:

    CASE WHEN `Lane` IN('A','B') THEN 'A to B'
    WHEN `Lane` IN('A','C') THEN 'A to C'

    ELSE 'Other' END

    I don't think I have enough information to write the exact beastmode you are looking for, but that should get you close. Let me know if this doesn't work for you!

    If I solved your problem, please select "yes" above

Answers

  • Have you looked into using variables to achieve this? https://www.domo.com/learn/video/variables-use-case-feature-walkthrough

    Was this comment helpful? Click Agree or Like below.
    Did this comment solve your problem? Accept it as the solution!

  • Answer ✓

    As bryce mentioned variables are a great way to do this if you want the axis values to change based on a filter. You could, however just group data together with a beastmode and then allow users to switch between that grouping as long as the aggregation remains constant (Sum, average, max, etc…) which it sounds like it is: % of shipments.

    Example Beastmode:

    CASE WHEN `Lane` IN('A','B') THEN 'A to B'
    WHEN `Lane` IN('A','C') THEN 'A to C'

    ELSE 'Other' END

    I don't think I have enough information to write the exact beastmode you are looking for, but that should get you close. Let me know if this doesn't work for you!

    If I solved your problem, please select "yes" above

  • @AdamC I agree with the above recommendations to use a variable. In this case, I suggest creating a numerical variable to represent the number of days you want to compare. Then your percentage beast mode would look like this:

    sum(case when `Days` <= `DaysVariable` then `Shipments` else 0 end)/sum(`Shipments`)

    So if a user has the card filtered to A to C, they can change the `DaysVariable` value to 4 to see what percent of shipments for that lane arrived within 4 days.

  • Member

    Thanks all. I haven't tried variable so I will run down that rabbit trail and see what I can come up with. Appreciate your help and insight. I think I need to understand variables before I can fully grasp the suggestions on how to work it.

    Thanks!

Welcome!

It looks like you're new here. Members get access to exclusive content, events, rewards, and more. Sign in or register to get started.
Sign In