To complete this recipe, do the following:
- Create the following measure:
ShannonEntropy =
SUMX(
ADDCOLUMNS(
SUMMARIZE(
'R01_Table',
'R01_Table'[Value],
"Probability",
DIVIDE(
COUNTROWS('R01_Table'),
COUNTROWS(ALL('R01_Table'))
)
),
"H(X)",
-1 * [Probability] * LOG([Probability],2)
),
[H(X)]
)
- On a Report page, create a Card visualization and place the ShannonEntropy measureĀ into the Fields area.