- SAP BusinessObjects Dashboards 4.1 Cookbook
- David Lai Xavier Hacking
- 558字
- 2021-07-23 19:44:06
Scaling the y-axis
After binding a chart to a dataset in the spreadsheet, SAP BusinessObjects Dashboards makes up a scale on the y axis by default, based on the lowest and highest values in the visualized dataset. The problem with this auto-scaling is that it creates a y-axis that doesn't start with 0, which may cause a bad interpretation of the data.
In the following screenshot, the same results are presented in two bar charts. The chart on the left-hand side gives the indication that Product B has performed a lot better than Product A; the bar is more than two times larger! This is, of course, wrong, as the y-axis starts at $470,000. The chart on the right-hand side shows a version that is much more useful for analysis.

Getting ready
You can reuse any of the dashboards you have already made with chart components. In this recipe, we will use the dashboard created in the Adding a line chart to your dashboard recipe.
How to do it...
- Select the chart, go to the Behavior tab, and select the Scale sub-tab. If your chart has a secondary axis, there will be two sub-tabs: Primary Scale and Secondary Scale.
- Select Manual (Y) Axis.
- Enter
0
under Minimum Limit and1000
under Maximum Limit. - Select Fixed Label Size.
- Set the Size of Divisions to
200
and Minor Divisions to1
:
How it works...
The y-axis of the chart will now have a fixed minimum and maximum limit. Remember that this also means that values higher than 1000 won't be displayed correctly with these settings. They will be placed on the maximum value (1000) of this chart.
The Fixed Label Size option keeps the labels on the -axis readable. 1,000 is 1K, 1,000,000 is 1M, a billion is 1B, and a trillion is 1T.
There's more...
We conclude this recipe with two additional options regarding scaling the y-axis: variable maximum limits and Allow Zoom Out Only.
To make sure that values in the dataset never pass the maximum limit, we can use a variable maximum limit by following these steps:
- Go to the spreadsheet and enter this formula in cell D1:
=MAX(B5:E7)
. This will result in the maximum value of the range B5 through E7. - Bind the Maximum Limit to cell D1. The y-axis will now display the exact maximum value that resulted from the formula.
- To make this value a more rounded number we have to adjust the formula. Change the formula to
=ROUNDUP((MAX(B5:E7)),-3)
. The -3 indicates that the value will be rounded up to the nearest thousand. So if the maximum value is 1978, the maximum limit on the y-axis will be 2000. -1 rounds to the nearest tens, -2 to the nearest hundred, and so on.
If you do want to use an automatic axis, SAP BusinessObjects Dashboards offers the Allow Zoom Out Only option. This option is only useful if a dataset that is presented in a chart is variable (for example, by switching with a selector; see Chapter 3, From a Static to an Interactive Dashboard). By selecting this option, the y-axis will only scale to larger values when a dataset with higher values is presented. If the values are lower, the scale will not change. With the slider, you can set the sensitivity of the growth factor.
- Machine Learning with R Cookbook(Second Edition)
- Mastering Python High Performance
- Python自然語言處理(微課版)
- Python機器學習:手把手教你掌握150個精彩案例(微課視頻版)
- Linux:Embedded Development
- C語言程序設計實驗指導 (第2版)
- Mastering Business Intelligence with MicroStrategy
- Getting Started with Eclipse Juno
- Java Web從入門到精通(第3版)
- 算法設計與分析:基于C++編程語言的描述
- Python預測分析與機器學習
- Android應用程序設計
- Analytics for the Internet of Things(IoT)
- Tkinter GUI Application Development Blueprints
- Building E-Commerce Solutions with WooCommerce(Second Edition)