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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
matsahiro
Helper II
Helper II

Making Lognorm.inv DAX run faster

Hello, I wrote this DAX calculating the inverse of a logarthmic normal distribution. DAX seems to be running very slow as there are about 10K records to calculate this for. Any tips on making it run faster? Thanks

 

LogNorm.Inv =

Var
    Sigma = sqrt(ln(1+50*power(sum(Table[Table_Column]),-.9)))
Var
    Mu = iferror(LN(sum(Table[Table_Column]))-DIVIDE(Power(Sigma,2),2),"")
Return
    IFERROR(EXP(Mu+Sigma*NORM.S.INV(Parameter)),"")
1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

Have you looked at the query in DAX Studio?  I would assume it lives entirely in the formula engine, but maybe there are some hints as to which part of the query you can cover with lookup tables.

 

You do error handling for the Mu part but then you ignore that again and brute force the inclusion of Mu on the return step.  You can replace that with a conditional calculation.

 

Please provide sample data in usable format (not as a picture) and show the expected outcome.

View solution in original post

1 REPLY 1
lbendlin
Super User
Super User

Have you looked at the query in DAX Studio?  I would assume it lives entirely in the formula engine, but maybe there are some hints as to which part of the query you can cover with lookup tables.

 

You do error handling for the Mu part but then you ignore that again and brute force the inclusion of Mu on the return step.  You can replace that with a conditional calculation.

 

Please provide sample data in usable format (not as a picture) and show the expected outcome.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

Feb2025 NL Carousel

Fabric Community Update - February 2025

Find out what's new and trending in the Fabric community.