Trying to show Churn (%) as a percentage and Churn (#) as a regular number
Basically What the title says, I'm trying to figure out what I need to add to my beast mode to be able to switch between the unit type on the axis. I want to display Churn (%) as a percentage (without multiplying by 100) and show Churn (#) as a number.
Attached is the beast mode that I have so far
Best Answer
-
Hi @miguel_bustamante,
What about using Tooltips? As shown in the screenshot, you can toggle between different currencies (in my case) and display the selected currency directly on the chart. I can also switch between Value and Quantity. You can adapt this in your scenario to switch between units and percentages. Please take note of the Beastmode I created and added to Tooltip field 1. I hope this addresses your request.Currency selected as CHF:
Currency selected as GBP:
Here is the Variable and Beastmode I'm using:
If you found this post helpful, please use 💡/💖/👍/😊 below! If it solved your problem, don't forget to accept the answer.
0
Answers
-
How about
CASE
WHEN `Churn Unit` = '% of Units' THEN CONCAT(ROUND(`Churn (%)`, 1), '%')
WHEN `Churn Unit` = '# of Units' THEN ROUND(`Churn (Units)`, 0)
ENDROUND(Churn (%), 1): Rounds the churn percentage to one decimal place. CONCAT(ROUND(Churn (%), 1), '%'): Appends a percentage sign to the rounded percentage value to display it as a percentage. ROUND(Churn (Units), 0): Rounds the churn units to the nearest whole number.
** Was this post helpful? Click Agree or Like below. **
** Did this solve your problem? Accept it as a solution! **1 -
@ArborRose This did not do anything. Is there maybe a change in my chart properties that could be causing this? Only properties I have set is Show total labels selected. and both Value Scale (y) and Category Scale (x) Titles set.
0 -
@ArborRose Looking at it, the data table is showing it as a percentage, but it is not carrying over to the actual chart.
0 -
If you're applying this Beast Mode calculation to a chart, ensure the chart type is compatible with mixed data types, as some chart types may not handle string formatting (e.g., concatenating a
%
) on axis values.1. Beast Mode Calculation with Mixed Data Types
- If your Beast Mode calculation returns different data types (e.g., a percentage and a whole number) depending on the conditions in your
CASE
statement, Domo might not automatically format the axis to correctly display both types. - For example, if one condition returns a percentage formatted as a string (e.g.,
"50%"
) and another returns a number (e.g.,1000
), Domo might not know how to handle this mix.
2. Setting Axis Formatting
- Explicit Axis Formatting: In the chart settings in Domo, you can often specify how the data on an axis should be formatted. For instance, you can set the axis to treat all values as percentages, numbers, or currency.
- Custom Number Formatting: In some cases, you might need to apply custom formatting rules to ensure that percentages appear with a
%
sign and numbers appear without it.
3. How to Adjust Axis Formatting
- Chart Properties:
- Go to the chart properties in Domo (click on the wrench icon in the chart's top-right corner).
- Navigate to the "Value Scale" section or "Number Formatting" section (depending on your chart type).
- Here, you can specify whether values should be treated as numbers, percentages, currency, etc.
- This setting can help Domo interpret the values returned by your Beast Mode calculation and display them correctly on the axis.
** Was this post helpful? Click Agree or Like below. **
** Did this solve your problem? Accept it as a solution! **0 - If your Beast Mode calculation returns different data types (e.g., a percentage and a whole number) depending on the conditions in your
-
How do i do the custom number formating… I looked through all the value scale options and number format options, not a single one lets me control the way that the data is displayed on a case by case basis they are all explicit formating. Explicit formating is not what I need because I need them to be different, thats the whole point of this post.
I need this to be some form of bar graph, and I currently have it set to the regular bar chart. Is there a specific chart that this works with that you can recommend? I have tried them all and none work. please let me know.
0 -
I don't know a specific chart type if custom formatting isn't available. I don't know all the options without trying to replicate the entire thing myself and see what's available. My approach would be to start creating some kind of custom output using a brick or possibly try to work with separate charts in a dashboard layout. One for Churn (%) and another for Churn (#).
** Was this post helpful? Click Agree or Like below. **
** Did this solve your problem? Accept it as a solution! **0 -
I just made it into two charts, but was really hoping to find a way to do just one. DOMO should really implement a way to due this naturally. Such a handicap to beastmodes that this cant be done.
0 -
Hi @miguel_bustamante,
What about using Tooltips? As shown in the screenshot, you can toggle between different currencies (in my case) and display the selected currency directly on the chart. I can also switch between Value and Quantity. You can adapt this in your scenario to switch between units and percentages. Please take note of the Beastmode I created and added to Tooltip field 1. I hope this addresses your request.Currency selected as CHF:
Currency selected as GBP:
Here is the Variable and Beastmode I'm using:
If you found this post helpful, please use 💡/💖/👍/😊 below! If it solved your problem, don't forget to accept the answer.
0 -
this is awesome thank you so much
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.9K Visualize
- 2.5K Charting
- 738 Beast Mode
- 57 App Studio
- 40 Variables
- 685 Automate
- 176 Apps
- 452 APIs & Domo Developer
- 47 Workflows
- 10 DomoAI
- 36 Predict
- 15 Jupyter Workspaces
- 21 R & Python Tiles
- 394 Distribute
- 113 Domo Everywhere
- 275 Scheduled Reports
- 6 Software Integrations
- 124 Manage
- 121 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