Altering a Column Calcuation Based on a Condition
I am creating ARM financial reports, and one of the columns included in the report is a % Change calculation. As an example, % Change for Actual (A) to Budget (B) would typically be calculated as (A-B)/B*100. However, whenever the divisor (B) is negative, the sign of the % Change is reversed. So, if the Actual was 100 and the Budget was -200, the result is -150%. However, 100 is an increase or improvement over -200, so the % should be positive.
How can I control the calculation for the column so that it effectively accomplishes If B>=0 then (A-B)/B else ((A-B)/B)*-1?
My question is related to this topic. I am new to Acumatica. I have built my reports with a variance column in my income statement. I am trying to build an IIF statement to essentially give me a favorable or unfavorable variance. For example, my income accounts need to subtract Actual minus Budget but my expense accounts need to subtract Budget minus Actual. This gives a more accurate view of the statement. I thought I could the account type, but that doesn't seem to be a parameter I can choose. Any suggestions?