Forum Discussion

Ruedi007's avatar
Ruedi007
Frequent Visitor
6 years ago
Solved

Y-Axis Slicer for different Value Fields

Hi!

 

I have a BarChart with Cities on the x-Axis. What I try to accomplish is to implement a Slicer where I can choose other Fields like

- Deaths

- Inhabitants

- Car Accidents asf.

I was able to find ways to make the x-Axis dynamic but not the y-Axis. If I put the different fields just as they are into the slicer I just see the values of the Fields.

 

Anyone who can help me out here or can link a tutorial?

 

Best!

2 Replies

  • v-juanli-msft's avatar
    v-juanli-msft
    Icon for Community Support rankCommunity Support

    Hi Ruedi007 

    Insert data to create a new table, add it to slicer,

    Measure =
    SWITCH (
        SELECTEDVALUE ( 'Table 2'[selection] ),
        "deaths", SUM ( 'Table'[deaths] ),
        "inhabitants", SUM ( 'Table'[inhabitants] ),
        "cars accidents", SUM ( 'Table'[cars accidents] )
    )
    

     

    Best Regards
    Maggie
    Community Support Team _ Maggie Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.