Difference between revisions of "IsSampleEvalMode"
m |
|||
Line 1: | Line 1: | ||
[[category:System Variables]] | [[category:System Variables]] | ||
− | IsSampleEvalMode is a system variable that returns True (1) when evaluated in Prob (probabilistic) mode or False (0) when evaluated in Mid (deterministic) mode. For example: | + | [[IsSampleEvalMode]] is a system variable that returns <code>True</code> (1) when evaluated in Prob (probabilistic) mode or <code>False</code> (0) when evaluated in [[Mid]] (deterministic) mode. For example: |
− | + | :<code>Mid(IsSampleEvalMode) → 0</code> | |
− | + | :<code>Sample(IsSampleEvalMode) → 1</code> | |
It is useful when you write an expression, e.g. a function, that uses different logic in each case -- for example: | It is useful when you write an expression, e.g. a function, that uses different logic in each case -- for example: | ||
− | + | :<code>If IsSampleEvalMode then <<logic to generate a sample>></code> | |
− | + | :<code>Else <<logic to compute the median>></code> | |
+ | |||
+ | ==See Also== | ||
+ | * [[Sample]] | ||
+ | * [[Statistical Functions and Importance Weighting]] |
Revision as of 00:55, 19 January 2016
IsSampleEvalMode is a system variable that returns True
(1) when evaluated in Prob (probabilistic) mode or False
(0) when evaluated in Mid (deterministic) mode. For example:
Mid(IsSampleEvalMode) → 0
Sample(IsSampleEvalMode) → 1
It is useful when you write an expression, e.g. a function, that uses different logic in each case -- for example:
If IsSampleEvalMode then <<logic to generate a sample>>
Else <<logic to compute the median>>
See Also
Comments
Enable comment auto-refresher