Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
avendanof
Helper I
Helper I

Show anual percentage growth in a line chart

I´m havin an issue trying to show a percentage anual growth using a line chart.

I have done this in a matrix using an expession like this

= Fields!Empresas.Value/sum(Fields!PrimerValorEmpresa.Value,"NombreNivel2Alt")*100

Where NombreNivel2Alt is a group value.

¿But is there a way to acccomplish something like this in a line chart?

 

The final chart shoud look like this:

avendanof_0-1700762012510.png

 

What I have in the axis y are percentages of grouth from a base year with a specific value.

Each group has a departing value, and is the total group value.

 

Here you can see how it works:

This are the group values

avendanof_1-1700762322924.png

And this are the rest of the data values which I use to divide by the group values:

avendanof_2-1700762452174.png

The last column is the percentage.

 

Now I need to convert this to a line chart

 

avendanof_0-1700762012510.png

 

Thanks for any suport on this.

 

 

3 REPLIES 3
MFelix
Super User
Super User

Hi @avendanof ,

 

Have you calculated the % column on your data? What does the model looks like?


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



In my data I only have the number of empresas month by month, and I have no %, In the Mathix I´m calculating the % right there, but I can´t do the same in the line chart. I´ve made a workaround using sql. But I still wonder if there is a better way to do this using formulas. 

The model has three tables, the Dim_date table,  the fact table with number of empresas and the Dim_Typeofempresa table. The fact table has only four fields, an ID, dates, TypeofempresaID, and ammount of empresa.

Hi @avendanof , 

 

Try the following code:

MFelix_0-1701858127251.png

% Grothw = VAR basevalue =
    CALCULATE ( MIN ( 'Calendar'[Date] ), REMOVEFILTERS ( 'Calendar' ) )
RETURN
    DIVIDE (
        SUM ( Empresas[Empresas] ),
        CALCULATE ( SUM ( Empresas[Empresas] ), 'Calendar'[Date] = basevalue )
    )

 

Be aware that this is always based on the lowest date of your date, and not restarted every year.


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.