Tuesday, August 11, 2020

How to create KPI measure in Power BI

If you want to build KPI visuals as it is presented on the screen below, you can achieve this by adding new measure and use the following DAX expression

KPI =
SWITCH (
TRUE (),
[Profit/Loss] > 0, unichar(9650),
[Profit/Loss] < 0, unichar(9660)
)

If Profit/Loss value is negative, you will have black down-pointing small triangle. If Profit/Loss is positive, you will have black up-pointing small triangle.

If you want to have different colors based on the values, you may use Conditional formatting as it is presented below.

No comments:

Post a Comment