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.” -Superman1 -
@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!
1
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.5K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 8 Federated
- 2.9K Transform
- 100 SQL DataFlows
- 616 Datasets
- 2.2K Magic ETL
- 3.8K Visualize
- 2.5K Charting
- 738 Beast Mode
- 56 App Studio
- 40 Variables
- 684 Automate
- 176 Apps
- 452 APIs & Domo Developer
- 46 Workflows
- 10 DomoAI
- 35 Predict
- 14 Jupyter Workspaces
- 21 R & Python Tiles
- 394 Distribute
- 113 Domo Everywhere
- 275 Scheduled Reports
- 6 Software Integrations
- 123 Manage
- 120 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 10 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 108 Community Announcements
- 4.8K Archive