Forum Discussion
Divide Function
- 4 years ago
Sheref_Morad
Here is your fil with the solution https://www.dropbox.com/t/CChylr4UPd28RtxH
Measures are automatically wrapped with CALCULATE which forces context transition. On the other hand using the formulas directly will be extremely complicated. Therefore, use can do the following:Predicted Income = Divide ( RELATED ( 'Regression Table'[y] ) - CALCULATE ( [b], ALL ( 'Regression Table' ) ), CALCULATE ( [m], ALL ( 'Regression Table' ) ) )This shall solve your problem.
Hi Sheref_Morad
I guess you have One to One relationship between the customer table and the regression table. In this case I think you've missed to wrap column [b] and column [m] with RELATED function.
- Sheref_Morad4 years agoFrequent Visitor
Hi tamer
thank you for answering, the problem is still the same M the other thing is m and b are measures not columns
Here the power Bi file I hope you yook take a look at it , specially the customer table and the regression table
https://bit.ly/3pzNo5r- tamerj14 years agoCommunity Champion
Sheref_Morad
Here is your fil with the solution https://www.dropbox.com/t/CChylr4UPd28RtxH
Measures are automatically wrapped with CALCULATE which forces context transition. On the other hand using the formulas directly will be extremely complicated. Therefore, use can do the following:Predicted Income = Divide ( RELATED ( 'Regression Table'[y] ) - CALCULATE ( [b], ALL ( 'Regression Table' ) ), CALCULATE ( [m], ALL ( 'Regression Table' ) ) )This shall solve your problem.