Syntax:
@if(test condition, execute if "true", execute if "false")
Executes one of two commands based on a condition. The condition can be a formula, string, list, or date, and must return true or false. You can nest @if statements.
For Net Income (v1750), if the common dividend payout percentage is based on the company's net income growth over the previous year, and:
If Net Income increases by at least 25%, the dividend is 20%
If Net Income is below 25%, the dividend is 15%
The formula for Common Dividends is:
@if((v1750-v1750(-1Y))/v1750(-1Y)>=25%, v1750*20%,v1750*15%)
If the model in example 1 is in quarters, but dividends are paid once a year at the fiscal year beginning, based on the prior year's net income, use a nested @if to calculate payment in the first quarter only:
@if(@qtrnum=1,@if((v1750(-1q)-v1750(-5q))/v1750(-5q)>=25%, v1750(-1q)*20%,v1750(-1q)*15%),0)
In the analyze trail, Strategic Finance returns 1 if the answer is "true", and a 0 if the answer is "false". |
Enter strings in quotes, for example: "Underwriting". Strings are case-insensitive, and are used as function arguments only to test formulas—they cannot be used as results.
@if(v1.0.600="Underwriting", v300*v305, @na)
because you can use strings in tests.
This is invalid:
@if(v155=v160, 300, "Revenue")
Lists behave like strings. Lists can be time series or scalar.
For example, if an account “Processed?” (v150.00.0000) has these possible values: Yes, No, Not Available—this is valid:
@if(v150="Yes", 100, 200)
In enumerated number lists, numbers are handled as strings, and entered in quotes. For example:
@if(v176="8", 300, 400)