Open In App

Power BI – Format Line and Stacked Column Chart

Improve
Improve
Like Article
Like
Save
Share
Report

A Line and Stacked Column chart is a combination of a line chart with a stacked column chart. We could add a secondary y-axis, with just 2 mouse clicks in Power BI. We have various options to format line and stacked column charts, we can change the value of the x-axis, y-axis, its title, etc. We can also add various options like series labels, markers, and data labels in this chart. In this article, we will learn how to format a Line and Stacked Column chart in Power BI and explore its various options.

Formatting a Line and Stacked Column Chart In Power BI

After the successful, creation of a line and stacked column chart in Power BI, we have multiple options to format it. For example, adding the title to the chart, changing the color, and position of the chart, and adding tooltips, bar colors, data labels, series labels, and total labels to the chart. We have been given a dataset, name, and Employee, and we have created the Line and Stacked Column chart, by adding the Employee name in the x-axis, bonus in the y-axis, and salary in the secondary y-axis. Using this chart, we will explore every option of this chart in Power BI. There are two types of Formatting in visualizations i.e. visual formatting and general formatting.

Power BI - Format Line and Stacked Column Chart

 

Visual Formatting

Visual formatting comprises 10 options i.e. Y-axis, X-axis, Secondary Y-axis, Legend, grid line, zoom slider, Lines, markers, columns, data labels, Series labels, and total labels.

Exploring Visual Formatting options in Power BI

 

X-Axis

The X-axis is the horizontal text of the chart.

The following are the steps:

Step 1: Click on the X-axis option. A drop-down appears. We have multiple options available here i.e. Values and Title. Click on the Values option, and a drop-down appears. For example, the values are Arushi, Gautam, etc. A font is an option used to select the type of text we want to show on the x-axis in the chart, we can also set the size of the text, etc.

Using Values feature of X-Axis

 

Step 2: Similarly, click on the title option. For example, the title is Employee Name. To change the color of the title of the x-axis, click on the color option. Select the required color. For example, we have selected orange color, and the Employee Name is changed to orange color.

Using Title feature of Y-Axis

 

Y-Axis

The Y-axis is the vertical text of the chart. It is present on the left side of the line and stacked column chart.

Exploring Y-Axis feature for formatting in Power BI

 

The following are the steps:

Step 1: Click on the Y-axis option. A drop-down appears. We have multiple options available here i.e. Range, Values, and Titles. Click on the range option, and a drop-down appears. Minimum and Maximum values can be set by the range option. By default, the minimum value is 0 and the maximum value is the maximum value of the dataset. We can also make the same chart, in a log scale, and can also invert the range of the y-axis.

Using Range feature of Y-Axis

 

Step 2: Click on the Values option, and a drop-down appears. For example, the values are 0K, 5K, 20K, etc. A font is an option used to select the type of text we want to show on the y-axis in the chart, we can also set the size of the text, etc. The units can also be customized, to million, thousand, etc.

Using Values feature of Y-Axis

 

Step 3: Similarly, click on the title option. For example, the title is Sum of Bonus. To change the color of the title of the y-axis, click on the color option. Select the required color. For example, we have selected orange color, and the Sum of Bonus is changed to orange color.

Using Title feature of Y-Axis

 

Secondary Y-Axis

The secondary Y-axis is also the vertical text of the chart. It is present on the right side of the line and stacked column chart.

Exploring Secondary Y-Axis in Power BI

 

The following are the steps:

Step 1: Click on the secondary Y-axis option. A drop-down appears. We have multiple options available here i.e. Range, Values, and Titles. Click on the range option, and a drop-down appears. Minimum and Maximum values can be set by the range option. By default, the minimum value is 0 and the maximum value is the maximum value of the dataset. We can also make the same chart, in a log scale, and can also invert the range of the secondary y-axis.

Using Range feature of Secondary Y-Axis

 

Step 2: Click on the Values option, and a drop-down appears. For example, the values are 40K, 50K, 70K, etc. A font is an option used to select the type of text we want to show on the secondary y-axis in the chart, we can also set the size of the text, etc. The units can also be customized, to million, thousand, etc.

Using Values feature of Secondary Y-Axis

 

Step 3: Similarly, click on the title option. For example, the title is Sum of Salary. To change the color of the title of the secondary y-axis, click on the color option. Select the required color. For example, we have selected orange color, and the Sum of Salary is changed to orange color.

Using Title feature of Secondary Y-Axis

 

Legends

Legends are the property that is used to sub-categorize the data for better analytics. It divides the data into different sub-groups.

The following are the steps:

Step 1: Click on the Legend option. A drop-down appears. We have multiple options available here i.e. Options, Text, and Title. We can set the position of the legends. Using the Text property, we can change the color and font size of the legends i.e. Department. Click on the Title, to customize the title i.e. Department.

Adding Legends in Power BI chart

 

Step 2: Click on the Options property, and a drop-down appears. We can set the position of the legends accordingly. For example, to Top Center, Bottom left, etc. By default, the Top left is the position.

Adding Legends in Power BI chart

 

Gridlines

Gridlines are the background lines, which are by default dotted in nature, and are very light and thin.

The following are the steps:

Step 1: Click on the Gridlines option. A drop-down appears. We have an option available i.e. Horizontal.  Click on the Horizontal option, and a drop-down appears. By default, in the line and stacked column chart, only horizontal gridlines are available. We can edit the style of the line. Also, one can set the color and change the thickness of the gridlines.

Adding Grid lines in Power BI chart

 

Step 2: Under the Style option, click on the drop-down option. A list appears. We can change the style of the horizontal gridlines to solid, dashed, etc.

Adding Grid lines in Power BI chart

 

Step 3: If we close the slider of the horizontal gridlines, then the horizontal lines would disappear, as seen in the image below.

Adding Grid lines in Power BI chart

 

Zoom Slider

The zoom slider is used to increase or decrease the range of the numeric values on the y-axis.

The following are the steps:

Step 1: Click on the Zoom slider option. A drop-down appears. We have multiple options available here i.e. Y-axis, Slider labels, and slider tooltips. A slider will appear on the y-axis of the chart. Slider labels, enable the values on the slider as a mark strip. Slider tooltips are used whenever we are sliding the zoom slider, the numeric value will appear on it.

Adding Zoom Slider in Power BI chart

 

Step 2: The below gif shows how the bars change with the slider.

Adding Zoom Slider in Power BI chart

 

Lines

Lines refer to the curve of the Salary dataset values. Click on the Lines option. A drop-down appears. We have 4 options i.e. Apply Settings to, shape, colors, and spacing

Adding Lines in Power BI chart

 

The following are the steps:

Step 1: Click on the Shape property. We can change the style of the line to dashed, solid, or dotted. Click on the colors property to customize the color of each of the lines of the legends. For example, change the color of the line to purple

Adding Lines in Power BI chart

 

Markers

Markers refer to the endpoints of each line. Click on the markers option. A drop-down appears. We have 3 options i.e. Apply settings to, shape and colors

Adding Markers in Power BI chart

 

The following are the steps:

Step 1: Click on the Shape button. A list appears for all different types of markers. Choose the marker as per your choice.

Adding Markers in Power BI chart

 

Columns

Columns refer to the bars of the line and stacked column chart. On the basis of different groups, we can set the color of the columns in this chart. For example, HR, IT, and Finance. These groups are classified on the basis of legends

Adding Columns in Power BI chart

 

Data Labels

Data labels provide additional information on the lines and columns of the chart. For example, Arushi and Gautam have a salary of 50K and 40K, and they want to display that on the bar. Click on the Data labels option. The salary data label will be added to the entire chart. Also, a drop-down appears. We have four options i.e. apply settings to, options, values, and background. Values and background have the same property as discussed above i.e. font, size, and color. Apply settings to, is a filter on the basis of legends, we can apply the property to specific groups only. The options property is used to set the position of the data labels.

Adding Data Labels in Power BI chart

 

Series Labels

Series labels display the name of the column of the line. For example, the Sum of Salary is the series label in this chart. All the options present in series labels are the same as data labels.

Adding Series Labels in Power BI chart

 

Total Labels 

Total labels are exactly the same as data labels. When we enabled the data labels option, we observed that the labels were shown inside the columns of the chart. Now, what if we want to show labels at the top of the chart? We can use, total labels to achieve it. Click on the total labels option. There are two properties of total labels i.e. Values, and Background. Values property is used to customize the font, size, and color of the total labels, and background property is used to change the color of the background of the total labels, in its certified area. 

Adding Total Labels in Power BI chart

 

General Formatting

There are multiple options in general formatting. For a  chart, we have options like Title, tooltip, effects, alt text, etc. We will look at each of the options in detail.

Exploring General Formatting in Power BI Chart

 

Property

The property option is generally present in every visualization. It contains three options, Size, position, and Advance options. We, generally do not use these properties, because all are easily accessible with mouse clicks. The size property helps to resize the visualization created. The position property changes the position of the visualization, in the report. The Advance option comprises adding a layer order, which is rarely used.

Adding Property in Power BI chart

 

Title

The title formatting is present in every visualization. As the name suggests, it adds a heading to the visualization. Click on the slider to enable the title.

The following are the steps:

Step 1: Click on the Title option. A drop-down list appears. Add the title, under the Text section. For example, the Sum of Bonus and Sum of Salary by Employee Name and Department. We can view in the image a title is added to the chart. As done previously we can customize the size, font type of the chart, etc.

Formatting title in Power BI chart

 

Step 2: We can also change the color of the title. Under the text color, select the required color. For example, yellow in this case. The title color changes to yellow.

Formatting title in Power BI chart

 

Effects

The effects section comprises three features i.e. Background, Visual Border, and Shadow. All works according to their names. The background adds a background color to the visualization, the Visual border adds a border around the visualization, and the shadow option creates a shadow on the outskirts of the visualization.

Adding Effects in Power - BI chart

 

The following are the steps:

Step 1: Click on the Background option. Select the color of the background accordingly. For example, Pink. We can view in the below image that the background of the chart changed to pink.

Adding Effects in Power - BI chart

 

Header Icons

Header icons are the options, present on the top of the visualization. For this chart, there are three options, filter on visuals, More Focus, and more options. Click on the header-icons option, we will get various options, like Background, Border, and Icons. One can set its colors as per choice.

Adding Header Icons in Power - BI chart

 

Tooltips

If we hover over a visualization, then we cannot view any information related to the chart. Consider a situation, where we want to display the fields added by hovering over the chart, then this task can be achieved by the Tooltips option. Tooltips have three properties i.e. Options, Text, and Background. Click on the tooltips option. Now, for example, we hover over the bar, then we can view that the employee Name Arushi, Department IT, Sum of Bonus 50K, and Total 20K. is displayed. We can set text and background color according to our needs.

Adding Tool tips in Power - BI chart

 

Alt Text

Alt text is a property present in each visualization. People generally misinterpret, alt text by its name, they think that alt text will be displayed when they hover over the visualization. Alt text is for the persons, who cannot see the visuals, images, etc. This option is only available if you are using a narrator in your system. When your narrator is active, then this alt text will be spoken by the system. Click on the Alt text, and type the required text. 

Adding Alt Text in Power - BI chart

 



Last Updated : 05 Feb, 2023
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads