Forum Discussion

Fapo's avatar
Fapo
Frequent Visitor
8 years ago

Monthly evolution through several years

Hello, my friends.

 

I have a report with a line chart. The line chart shows the monthly evolution of costs. So far, so good.

But now I added a Year slicer, and I want to be able to select two years at the same time in order to get, for example, the monthly evolution of costs on 2015 compared to 2018 (so: the costs on Juanuary 2015, February 2015, March 2015...January 2018, February 2018, etc...).

 

Note that I want the months of the first year first...the months of the next year later...and so on.  I do NOT want January 2016, January 2017, January 2018 first, then February 2016, February 2017, February 2018, etc...

 

The issue is that, when selecting multiple years simultaneously, Powe BI takes the sum of the value for that month on all the years I've selected, and then averages that quantity. So, instead of bringing the costs on January 2016, the costs on January 2017, and the costs on January 2018, it simply throws the averaged sum of all of them as "January". The average of January in 2016, 2017 and 2018...the average of Feubrary in 2015, 2017 and 2018...and so on.

 

How can I get what I want?

 

Thanks in advance!

 

2 Replies

  • Hi,

     

    Instead of adding Year to the slicers, add them to the X-axis.

     

    Does that work?

  • v-jiascu-msft's avatar
    v-jiascu-msft
    Icon for Microsoft Employee rankMicrosoft Employee

    Hi Fapo,

     

    Seems you have two issues. Can you share your file or a dummy sample? It's hard to troubleshoot the wrong results without data.

     

    Best Regards,

    Dale