Examples of Gretl scripts
by Carlos Andrade

Dear All,
Where to get examples of Gretl scripts for different types of analysis?
--
Atenciosamente,
Prof. Carlos A. S. de Andrade
LAPEA - Laboratório de Pesquisa em Economia Aplicada e Engenharia de
Produção
Universidade Federal de Campina Grande.
Centro de Humanidades
Unidade Acadêmica de Economia
11 years

Re: [Gretl-users] GARCH, Forecasting
by Allin Cottrell

On Mon, 17 Jan 2011, [ISO-8859-1] Alejandro Mosi�o wrote:
> Maybe i was not too much specific last time:
>
> I have a variable "y" that follows a GARCH(1,1) process. Then, i Gretl i
> type:
>
> garch 1 1 ; y const
>
> Then i got the result and forecasting the out-of-sample values of y can
> be done in the usual way. However, i'm interested in forecasting the
> out-of-sample variance. I don't know if such a function exists in Gretl.
There is no built-in function to do this, but you can compute a
one-step ahead forecast of the variance from the model data, as
hown in the following example script.
<script>
open b-g.gdt
garch 1 1 ; Y
series e = $uhat
series h = $h
dataset addobs 10
a0 = $coeff[2]
a1 = $coeff[3]
b1 = $coeff[4]
series hfc = h
# set future errors to their expectation
e = misszero(e)
# forecast the variance
hfc = a0 + a1 * e(-1)^2 + b1 * hfc(-1)
smpl 1970 ;
print e h hfc --byobs
</script>
Allin Cottrell
11 years, 5 months

How to reference a separate time observations for a given time series in gretl?
by huugh＠centrum.cz

Hi,
is there a way how to reference a separate time observations for a given time series in gretl?
For example, if I wish to compute a "recession" dummy, i.e. an indicator with 1, if in the two last periods there were negative growth rates and 0 otherwise?
E.g. let's have this time series called X (below is some data, with the obs. number and growth rate)
Obs. no X ln(X)-ln(X(-1))
1 34296
2 30383 -0.121145488
3 28899 -0.050076249
4 27669 -0.04349434
5 26303 -0.050629652
6 26206 -0.003694609
7 26687 0.018188163
8 26424 -0.009903867
9 25458 -0.037242653
10 23749 -0.069489611
11 24709 0.039627125
12 25151 0.017730107
13 24431 -0.029044839
14 25740 0.052193384
15 26240 0.019238762
16 25999 -0.009226888
17 26420 0.016063223
18 25847 -0.021926759
19 25660 -0.007261181
20 24407 -0.050063383
21 25618 0.048425253
What command would generate the values of 1 for periods with two consequtive negative values in series? I.e. I would get this series:
n/a
n/a
1
1
1
1
0
0
1
1
0
0
0
0
0
0
0
0
1
1
0
Thanks,
Vladimir
11 years, 7 months

How to look up code "behind" commands and functions
by Andreas Tudyka

Hi I am new to gretl and I am trying to find out how the calculations
behind different commands are done.
For example, if I run the pca command I would like to see how exactly the
eigenvectors are multplied with my data and how the data is standardized
etc.. This also applies to the princomp function.
Is it possible to look "into" these commands and functions or would I have
to resort to some source code in C?
Thanks,
Andy
11 years, 7 months

GRETL users stackexchange site for more accessible exchange of knowledge
by Trevor Zink

Hi gretl users,
In my Aug 22, 2012 post (here:
http://lists.wfu.edu/pipermail/gretl-users/2012-August/007948.html) I
suggested that we look into switching to a format like stackexchange.com,
where users can ask questions and the best answers get sorted to the top for
later users to easily find information they're looking for. For a great
example of a thriving stackexchange community, check out
http://tex.stackexchange.com.
The thread died out pretty fast, but I am hoping maybe that's because
everyone is busy and didn't want to through the legwork of setting up a
stackexchange site. It turns out that it's extremely easy, so I did it
myself.
You can visit it here:
http://area51.stackexchange.com/proposals/43782/gretl?referrer=H784Ua9YLHQ1E
f1WF8pECg2
The site will remain in this "area 51" limbo stage until it reaches 60
followers and 40 questions with a score of 10 or more. So when you visit the
site, be sure to log in (you can use a Google, Yahoo, or any OpenID login)
and click "follow" on the left-hand side. I know there are many more than 60
people out there using GRETL, so let's get the word out and soon we too will
have a thriving Q&A community.
I took the liberty of posting a few recent questions from the mailing list
so you can see how it works. Keep in mind the example questions are only
question *titles*. Real questions could include long descriptions, example
code, images, links, etc. You can also post example questions of the sort
you'd like to see discussed on the site.
I really think this is a valuable direction to take this knowledge
community, and I hope you agree. See you there!
Trevor
11 years, 7 months

MCMC for dummies?
by Allin Cottrell

This may appear to be totally off-topic but it's not entirely so,
given that we've had a "feature request" at sourceforge for a Gibbs
sampler implementation. Anyway, does anyone have a recommendation
for a sort of "Markov Chain Monte Carlo for dummies" -- a useful
book, article or website?
I understand the principles of Monte Carlo analysis pretty well;
I've read some interesting arguments in favour of a Bayesian
approach in statistics (though I'm basically a frequentist); and I
have some notion of what Markov chains are; but I'm having trouble
putting the whole picture together.
That is, if we start from some econometric problem, and we assume
some relevant data are available -- and maybe we also assume that I
have some prior beliefs about the problem in question that could be
quantified to some extent, in some way -- how exactly could I use
MCMC to arrive at "better" (in what sense?) parameter estimates,
confidence intervals for these estimates, forecasts, and confidence
intervals for the forecasts, than I could obtain via regular OLS,
GLS, MLE, or GMM?
I'm not asking people to explain this to me here, just to give any
references that they have found particularly useful.
Thanks.
Allin Cottrell
11 years, 7 months

Cannot Plot Graphs
by Mika'ilu Abubakar

Hi,
I recently had my computer reformatted. I've reinstalled gretl (version 1.9.9) but I keep getting the following error message: "C:\Program Files\gretl\wgnuplot.exe" "C:\Users\Mika'ilu Abubakar\AppData\Roaming\gretl\gpttmp.a03076": exit code 1, whenever I want to plot a graph. What could possibly be wrong?
Regards,
Mika'ilu Abubakar
11 years, 7 months

(no subject)
by Mika'ilu Abubakar

Hi,
I recently had my computer reformatted. I've reinstalled gretl (version 1.9.9) but I keep getting the following error message: "C:\Program Files\gretl\wgnuplot.exe" "C:\Users\Mika'ilu Abubakar\AppData\Roaming\gretl\gpttmp.a03076": exit code 1, whenever I want to plot a graph. What could possibly be wrong?
Regards,
Mika'ilu Abubakar
11 years, 7 months

Problems downloading Gretl
by Ben Bostick

Hello,
My name is Benjamin and I'm a student at Florida State University. Recently
I attempted to download Gretl for one of my classes. I have a Macbook Pro
version 10.6.8, and after I follow the instructions on downloading Gretl,
the program itself refuses to open. When I click the Gretl Icon, it reopens
the driver used to download the program, but it won't run the program
itself. I've seen some tips including using X11 and the GTK framework to
run the program, but typing in the README-suggested prompt in the xframe(cd
/Applications/Gretl.app/Contents/Resources/bin ./gretl) produces no
results. Any help you could offer in this problem would be much
appreciated.
Thank you for your time,
Benjamin Bostick
11 years, 7 months