Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello World!
Is it possible to code this in DAX - im having a hard time doing so and reltively new to DAX!
=(X/Y)^(1/((P-Q)*100))-1
Where X and Y are related in the same column - P and Q are also related in the same column.
However X and Y are not in the same column as P and Q
X is in the same row as P, Y is in the same row as Q
However X and P are not in the same row as Y and Q
X | P |
Y | Q |
Finding it hard to relate to a specific cell in DAX
Easily in Excel, but seems not possible in DAX, where the data is evaluated column by column. If you look at the DAX codes, mostly refer to columns or tables.
X & Y are given net conversion rates whist P & Q are Distrupts
For example
-0.02 | 0.75% |
0 | 0.50% |
I think its worth noting that the table would look like this, so would need more than a 2x2 table and i would like it to update when the data refreshes (if possible)
Disrupt | Header | Header | Header | Header | Header | Header | Header | Header |
-0.02 | Cell | Cell | 0.75% | Cell | Cell | Cell | Cell | Cell |
Cell | Cell | Cell | Cell | Cell | Cell | Cell | Cell | Cell |
0 | Cell | Cell | 0.50% | Cell | Cell | Cell | Cell | Cell |
I think I need somehting to refer to a specfic cell in a way
Hi,
There is a hidden function called OFFSET which can help you.
E.g.
Data:
Dax:
There are also other ways to do this kind of calculation using idex, but here I am specifically using relation to other "cells" as the basis for calculation.
Proud to be a Super User!
I believe it could be possible... however, how are X&Y and P&Q related in the table? Is it just consecutive records, or dates ? Can you share sample data
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
39 | |
25 | |
20 | |
14 | |
8 |
User | Count |
---|---|
71 | |
48 | |
46 | |
20 | |
16 |