Viz.Area¶
Renders an area chart as an SVG data URI showing measure values across an axis with filled area
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| axisRef | ANYREF EXPR | Axis reference column | ||
| measureRef | NUMERIC EXPR | Measure expression | ||
| color | STRING | BLANK() |
Optional series color. Defaults to Power BI theme color | |
| showAxis | BOOLEAN | FALSE() |
Optional axis toggle. Defaults to FALSE | |
| width | INT64 | 120 |
Optional: SVG width. Defaults to 120 | |
| height | INT64 | 48 |
Optional: SVG height. Defaults to 48 |
STRING SVG Area Chart
function 'DaxLib.SVG.Viz.Area' =
(
axisRef: ANYREF EXPR,
measureRef: NUMERIC EXPR,
color: STRING = BLANK(),
showAxis: BOOLEAN = FALSE(),
width: INT64 = 120,
height: INT64 = 48
) =>
VAR _Marks =
DaxLib.SVG.Compound.Area(
0, // x
0, // y
width, // width
height, // height
axisRef, // axisRef
measureRef, // measureRef
color, // fillColor
color, // strokeColor
, // fillOpacity
, // minMarkColor
, // maxMarkColor
showAxis // showAxis
)
RETURN
IF( NOT ISBLANK( _Marks ), DaxLib.SVG.SVG( "100%", "100%", _Marks, "0 0 " & width & " " & height ) )