Some parameter names generate errors

Some of the parameter names (even very innocent ones) seem to be generating an error in my code. The attached code, for example, works just fine. But when I replace parameter name “theta” with a parameter name “lambda” (using Replace All function, I get 20 replacements), I get an error message saying that: “The input character is not valid in MATLAB statements or expressions”.

Any suggestions would be very much appreciated.

Many thanks,

tokhir
OP_model.mod (2.38 KB)

I can’t reproduce the problem. OP_model.mod works on my machine in Dynare version 3 and in version 4 under Windows. Under which operating system are you working? which Matlab version ?

Best

Michel

The problem is with upper and lower case. For example, you can’t have v1 as a parameter and V1 as a variable. There is some inconsistency in the handling of upper and lower case in Dynare version 3. So you should be case consistent, but not rely on it to distinguish objects.

Kind regards

Michel