Normally don't read papers for the purposes of answering forum questions, but it looked like it would be easy so I took a quick look. I only glanced at the first bit, but if I'm understanding correctly, something like
should do the trick for k=30.
First line ranks all of the observations in the series (in my case CONS) in descending order.
Next two lines compute the value of the series for the !k+1 rank.
Last two lines restrict sample to the first k descending order statistics, and compute the mean of the log of the scaled data.
Note that as with many things in EViews, you are far better trying to do things using series generation which allows you to avoid loops.
Hope this answers the question.
Code:
!k = 30
series rnks = @ranks(cons, "d")
smpl if rnks = !k+1
scalar scale = @mean(cons)
smpl if rnks <= !k
scalar alpha = 1 / @mean(@log(cons)-log(scale))
should do the trick for k=30.
First line ranks all of the observations in the series (in my case CONS) in descending order.
Next two lines compute the value of the series for the !k+1 rank.
Last two lines restrict sample to the first k descending order statistics, and compute the mean of the log of the scaled data.
Note that as with many things in EViews, you are far better trying to do things using series generation which allows you to avoid loops.
Hope this answers the question.