Page 1 of 1

Loop Equations Yearly

Posted: Wed Jul 31, 2024 11:40 am
by CNR15
Hi - I am looking to loop the below so they are recalculated every year. Any idea a better way than the year by year approach below?

Thanks!

smpl 2022 2022
series cap = (1-d)*cap(-1) + inv(-1)
series y = ia*(cap^alpha)*(lab^(1-alpha))
series inv = r*y

smpl 2023 2023
series cap = (1-d)*cap(-1) + inv(-1)
series y = ia*(cap^alpha)*(lab^(1-alpha))
series inv = r*y

smpl 2024 2024
series cap = (1-d)*cap(-1) + inv(-1)
series y = ia*(cap^alpha)*(lab^(1-alpha))
series inv = r*y

Re: Loop Equations Yearly

Posted: Wed Jul 31, 2024 1:54 pm
by EViews Gareth
The loops don't really make sense. Is there any reason you cannot simply do:

smpl 2022 2024

series cap = (1-d)*cap(-1) + inv(-1)

series y = ia*(cap^alpha)*(lab^(1-alpha))

series inv = r*y