If statement

Hi,
I would like to know if it is possible to use the conditional statement “if” with a model variable. Something like:

@#if model_variable <= value
equation1
@#else
equation2
@#endif

Best regards, Márcio.

No, that is not possible. Macro-processor statements are evaluated before processing the model. Therefore, the value you test must be known in advance. I guess you have in mind a model where endogenously you use either one or the other equation depending on the value of the variable in that period. That is a different issue than constructing a mod-file. You may be able to work with a min/max construct to get the desired result.