e.g. first example
random Real strength(Person p) ~ Gaussian(10, 2);
random Boolean lazy(Person p, Match m)
~ BooleanDistrib(0.1);
random Real pulling_power(Person p, Match m) ~
if lazy(p, m) then strength(p) / 2.0
else strength(p);
Using fixed random seed for repeatability.
tst.blog::1.22: Type Person undefined!
tst.blog::2.21: Type Person undefined!
tst.blog::2.31: Type Match undefined!
tst.blog::4.27: Type Person undefined!
tst.blog::4.37: Type Match undefined!
tst.blog::1.22: Type Person undefined!
tst.blog::2.21: Type Person undefined!
tst.blog::2.31: Type Match undefined!
tst.blog::4.27: Type Person undefined!
tst.blog::4.37: Type Match undefined!
e.g. first example
gives output