On Wed, 21 Oct 2020, Fred Engst wrote:
[M]y purpose is to see the distribution of the panel adf test, but
in panel adf, I can’t retrieve the test statistics, nor the
p-value of the test using $pvalue or $test.
What should I do?
You should be able to get $test and $pvalue using the "levinlin"
command. As for "adf" itself, in the panel case as things stand
you'd have to save results by "scraping" the output, as illustrated
below.
<hansl>
function matrix panel_adf_pv (string s)
string line
matrix pv = {}
loop while getline(s, line)
lb = strstr(line, "[")
if lb != ""
pv ~= atof(lb+1)
endif
endloop
return pv
end function
open grunfeld.gdt
string s
outfile --buffer=s
adf 2 value --quiet
end outfile
matrix pvs = panel_adf_pv(s)
print pvs
levinlin 2 value --quiet
eval $test
eval $pvalue
</hansl>
Allin