Problem with external shocks: shocks(shocks_file=datafile)

Dear experts,

When I want to include a formerly estimated TFP shock series into a simple deterministic model, using the command ‘shocks(shocks_file=datafile.mat)’,

Matlab reports: (for the ‘shocks’ line)
ERROR: syntax error, unexpected ‘(’, expecting ‘;’

Could you tell me what is the problem with this command? I guess a possible reason is that the shocks_file command is not used in Dynare4 anymore. I do find it in old version Dynare 3.065, but when I run the model in Dynare3, it sitll reports sytax error.

If can not not use the shocks_file option, is there any other method to bring into the model such a external TFP shock serie?

In the newest Dynare User Guide:

4.1.4 Referring to external files
------But you may also be interested in the second possibility described above,
namely of specifying shocks in an external file, to simulate a model based on
shocks from a prior estimation, for instance. …Finally, you could simulate a deterministic model with the shocks saved from
the estimation by specifying the source file for the shocks, using the
shocks(shocks file = datafile.mat) command.

Some one has asked this question before, but seems no answers…
the similar question’s link:

This is another quesion and answer, but it can not help with my Error report when running, by the way, its attached file is not downloadbale?

Thank you so much!
model0.rar (2.25 KB)

Looks like you forgot a semicolon after the command.

However I cannot open your MOD file: you should probably post them directly, not in a RAR (or alternatively use a more standard format like ZIP).