Closed salbalkus closed 3 months ago
Sometimes we might want to assign a static variable in a DGP and use it later because it encapsulates a long line of code, i.e.
@dgp( L1 ~ Exponential(1), L2 ~ Poisson(3), L3 ~ Beta(3, 2), L4 ~ DiscreteUniform(-3, 2), μ = (@. 0.01 * exp(:L1 + :L2 + :L3 + :L4 + 10) + 0.5), A ~ (@. truncated.(Normal(:μ, 1), μ - 2, μ + 2)), Y ~ (@. Normal(:A + 0.01 * :L1 + 0.1 * (:L2 + :L3 + :L4), 1)) );
The dgp macro might be modified to support this.
dgp
Sometimes we might want to assign a static variable in a DGP and use it later because it encapsulates a long line of code, i.e.
The
dgp
macro might be modified to support this.