I have some calculations I'm working on in regards to breakeven bushels per acre. What I am seeing is that if I have a table showing data at the lowest level in a table visual, it works fine. The calculation is also correct at the total (all crops) level. It's a basic calculation of Total Expenses / Actual Harvested Acres.
However, when I use a hierarchy and show the data in a summarized form, the calculation is doing something different. The calculation works at an individual field level, but when the data is in a different visual and shown at the crop level (multiple fields), I'm not sure how I need to change the calculation. I think I'm missing something in regards to getting just the subset records.
In my PBIX file, I have a few sample measures.
Crop (Corn, Wheat, Soybeans)
Class (Individual field)
I have written this calculation a few different ways with similar results so I think it is a logic error I'm missing.
The total level is correct (122109.4 Total expenses / 1320.1 Acres = 92.50008)
Both breakeven calculations are correct, see example for winter wheat:
B1: (27091.39 / 283.90 = 95.43)
B2: (5312.06 / 53 = 100.23)
Crop level incorrect:
Expected value for Winter wheat: 32403.45 / 336.9 = 96.18121
Actual value for Winter wheat: 24.55
Thanks for any suggestions. I've found numerous posts pointing to do a percentage of total calculation that needs to be adjusted, but I think my problem needs to be solved by ensuring I have the correct subset of records, which I think is where I am going wrong.
Edit1: Here is an updated link that looks to work for me.
Solved! Go to Solution.
Hi @Ashish_Mathur, Thanks for taking the time to reply. It does indeed look like your suggestion resolved the issue.
It appears the issue was that my hieararchy was returning different results versus individually dragging the different hieararchy values in.
If this is by design or if there is any documentation to relect this, I'd love to know a little more. Otherwise I'm happy with the issue resolved. Thank you again!
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
Welcome to the Power BI Community Show! Jeroen ter Heerdt talks about the importance of Data Modeling.
Mark your calendars and join us on Thursday, May 26 at 11a PDT for a great session with Ted Pattison!
Put your data visualization and design skills to the test! This exciting challenge is happening now through May 31st!