Why it appears "syntax error, unexpected NAME"

yizhi520.mod (4.5 KB)
Hello Professor, sorry to bother, I really need your help. I’m really confused about what causes this to happen.why it appears “syntax error, unexpected NAME”
I am looking forward to your reply and guidance
Thank you very much!!

There is a closing semicolon missing at the end of line 69. Also, only do the exp-substitution once the model works.

Dear Professor, thank you for your reply, I have added the missing semicolon and the model still does not work. Can you tell me how to correct it? In this model I added the heterogeneity of the family, and maybe I made something wrong.
yizhi520.mod (4.5 KB)

I don’t know why the sum of square residuals of the static equations is so large

I already told you:

You have for example wrong brackets.

Do you mean I run the code without exp first? I’m very sorry that my question may be a bit low-level, because I am a beginner and may need you to say more details, for which I am very grateful

yizhi520_1.mod (3.9 KB)

Hello professor, I wrote the code using the model before the exp-substitution, and it still didn’t work, can you tell me how to modify it?

Put resid before steady to see the problematic equations. Also, in your parameter definitions, you have


Here, you use site before it was computed.

Thanks for your reply and guidance, I will check again to correct my model

Hello professor, I have checked and modified my model, but it still does not work, is my steady-state value solution wrong?can you please see where the problem is, this really makes me too confused, this is my new code,thank you
modify523.mod (3.9 KB)

Put resid before steady. You will see a couple of problematic equations.

I’ve added resid, but I don’t know how to correct it, can you give me a little advice, or give me an example, thanks, it really confuses me

Sit down with pencil and paper and compute the steady state be hand. It seems you attempted this, but there must be a mistake somewhere as your initial values lead to big residuals in the Euler equation and the labor FOC. If your model is too complicated to do that, use a smaller model.

You’re right, I’ve already calculated it with a pen. I would like to ask whether it is reasonable to let A_SS = 1 in this model?

This is a normalization you are allowed to do. But then you cannot have y_ss=1