Unable to Display Stacked Bar Due to Partition Beast Mode

At the base, my dataset is broken up by employeeID, months, and planID. For each of the employees, month and plan; the employee receives a $ value based on performance, called "Earned" and they also have a column "Funded" that indicates what they were funded for the plan and month.


I am trying to create a card that displays the month on the x-axis (with the option to use different graph by groupings like quarter, using the month date value) and the y-axis will show a distinct count of plans for the given timeframe broken up by a color grouping. The color grouping should be calculated based on the earned and funded value for the plan for the given timeframe. The general logic is

Budget color rules by plan and timeframe:

Earned < 85% of the Funding amount = Yellow

Earned between 85-115% of the Funding amount = Green

Earned > 115% of the Funding amount = Red

Ex//

The x-axis is displaying quarters and the y-axis might show 100 distinct plans for the quarter, but 25 are green, 50 are yellow, and 25 are red - as a stacked bar.


I believe I have the plan color beast mode setup correctly for the color rules (screenshot below) since when I display the data in a table it seems to be calculating everything correctly (screenshot below). The table shows the month, plan color, planID and then the calculation that I use to determine the color of the plan - the same as the beast mode, just without the THEN 'colors'


I'm running into the issue when I try to create the stacked bar chart. What I have done for similar situations is using a distinct count for the y-axis and then include the colors in the series to differentiate/break out the distinct count on the y-axis. I think because my beast mode uses partition by planID I'm not able to aggregate for the entire timeframe on the x-axis. Below is a screenshot of what I see, the y-axis value is a beast mode that is just 'COUNT(DISTINCT `PLANCODEID`)'


I'm not sure if there is a better way to do this, but I don't believe I can do the color beast mode in the dataflow since they want to be able to change the x-axis timeframe between months and quarters, eventually years - quarters will also be the default, it's just easier to show in months for this.

Any help/ideas would be greatly appreciated!

Answers

  • @jdorsch2 can you share what you have in your sort properties as well?


    “There is a superhero in all of us, we just need the courage to put on the cape.” -Superman
  • @ST_-Superman-_ Thanks for replying! Sadly, I deleted this card, so I'm not sure if I had anything in the sort section. I believe I removed everything in sort and chose specific columns to see if that was affecting it, since I know Domo won't display values grouped together if they have different values in the columns that you're sorting on. I think the issue was something around the multiple partitions that conflicted or maybe Domo can only partition so many times?

    I ended up trying a different approach by using some group by calculations in a dataflow for the different time period scenarios and then setup a variable to have the user select how they wanted to display, like months, quarters, years, etc. That ended up working pretty well.

    I appreciate you reaching out to help tho!