Forum Discussion
Multiply Values from Single Column
OK, am I crazy to point out that multiplying the inverse of the ratio does not produce the same result as dividing the numbers? See PBIX attached. PRODUCX('Table', 1/[Ratio]) with the sample data returns 1.75 while dividing the numbers returns 3.24. Where is my math failing me?
Hi Greg_Deckler
You are 100% correct but it is just about the first value which goes the numerator, this is what I was asking for a unique date or index column to calculate the first value visible in the current filter context and divide it by the result of the PRODUCTX after filtering out the very same value from the table. Not sure if jbaisley has double checked the results not even sure if this is what he wants or in fact he just wants to have the result of the PRODUCTX right away.
I don't know what is this calculation about but to me it makes more sense to say that divide the ratios by each other means 1/R1/R2/R3/......etc
- jbaisley3 years agoHelper I
Thanks folks,
The use is a dodgy pooled ratio calculation. In theory (I cannot stress that enough) you can divide indivudal probabilty ratios to get a joint odds ratio. There is lots of pre-work to ensure that the ratios are correct and you need to be super careful that the ratios are coming from the same popualtion size. Typically you would only attempt this with perfect knowledge of a popualtion, instead we are using prevelance rate statistics to make odds ratios. The client has asked to be able to see their corss impact on one another, hense pooling them (again should only be done in specific circumstances). As both of you have discovered the results are suspect, but we needed to build it to prove the point. So it does work as intended 🙂
-Jacob
- Greg_Deckler3 years agoCommunity Champion
tamerj1 OK, I just wanted to make sure I wasn't going crazy. Does seem like there ought to be a PRODUCTX equivalent in DAX, DIVIDEX? Otherwise, to truly get the division of a column of numbers seems to stray into the recursive space and we all know where that leads...