Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
7 years ago
Solved

Combining 2 slicers data in a single line graph

Hello,

 

I'm trying to implement this for the last 2 days, without any luck with any the solutions found in this community.

 

I have two slicers with a sub-set of data from the same column (different types). I want to choose multiple from each slicer to be able to show this measure on a line graph for each of the chosen ones. 

 

Measure: 

FundReturn100 =
VAR Fundbase =
CALCULATE (
SUM ( AssetReturns[price] );
FILTER (
ALLSELECTED ( AssetReturns[assetdate] );
AssetReturns[assetdate]
= CALCULATE ( MIN ( AssetReturns[assetdate] ); ( ALLSELECTED ( AssetReturns ) ) )
)
)
RETURN
CALCULATE ( SUM ( AssetReturns[price] ) ) / Fundbase
* 100

 

Currently, I am able to choose multiple for both slicers, but once I choose the first from the other slicer everything disappears from the graph.

 

Thank you in advance for your help.

 

 

5 Replies

  • Can you describe the problem? It is not very clear with formula.

    But In case you want one with time and one without time. Then let sum for data come using the slicer on the page(if there is one) and user except to avoid date filter to get GT

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks for the quick reply :) And sorry for not being clear enough, but I am totally on PowerBI. 

      I will try to clarify it:

      - 1st slicer has the type 1 list of products; (slicing by name)

      - 2nd slicer has the type 2 list of products: (slicing by name)

      - The graph has the value calculated by the formula; (correctly showing the result when only one of the slicer has selections)

       

      The idea is to give the user the possibility to compare N to N products of the different types in the graph.

       

      I hope it was more clear :)

       

       

       

       

      • Anonymous's avatar
        Anonymous
        Not applicable

        Maybe sharing the pbix file is easy to understand what I need to show on the graph.

        PBIX

         

        Best,