21. Dynamic Charts: Field Parameters, What-if and Dynamic Top N
21.2 Field Parameters: Switch Dimensions (Dynamic Axis)
Steps in Power BI
- Modeling › New parameter › Fields › Name
Axis Selector. - Tick
DarkStore[City],Product[Category],Orders[Payment Mode],Orders[Order Hour],Orders[Platform]› Create. - Bar chart: Y-axis = Axis Selector, X-axis = Metric Selector (from 21.1). Now users choose both what to measure and by what.
- For a dynamic date granularity, create a parameter with
'Date'[Year],'Date'[Year Month],'Date'[Date]and use it on a line chart's X-axis.
Ravindra Bagale's Tip
Mitrano, ithe chuk karu naka: multi-select in a field-parameter slicer adds several fields to the chart at once, which confuses users, so use single select. Also check the sort after switching fields (… › Sort axis), karan the visual sorts by whichever field is currently selected. Ekdum simple aahe, fakt savay lavun ghya.