Where to get examples of Gretl scripts for different types of analysis?
Prof. Carlos A. S. de Andrade
LAPEA - Laboratório de Pesquisa em Economia Aplicada e Engenharia de
Universidade Federal de Campina Grande.
Centro de Humanidades
Unidade Acadêmica de Economia
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
> 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.
garch 1 1 ; Y
series e = $uhat
series h = $h
dataset addobs 10
a0 = $coeff
a1 = $coeff
b1 = $coeff
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
Just a general VAR related question. When is it appropriate to include
a deterministic time trend in the reduced form VAR? Visually some of the
data series (not all) look like they have trending properties. In any case,
does the inclusion of the time trend matter if the process is stable and
therefore stationary (i.e. the polynomial defined by the determinant of the
autoregressive operator has no roots in and on the complex unit circle)
without the time trend term. Other than unit root tests, is there a better
way to test whether the underlying data generating process has a stochastic
or deterministic process?
I am mainly interested in the impulse responses.
Dear Gretl Community,
Is there any way to retrieve the roots of an ARIMA model? Is there an
accessor that allows this kind of operation?
My aim goal is to build an automatic ARIMA modelling script that saves only
the models with signicant parameters and roots outside the unit circle.
I have a problem for a long time, it begin with 1.9.5 version I can't open
any file, neither to do any operation, Gretl crash and close,
my system is ubuntu 10.4 and I did install Gretl using tar.files.
I try next:
- Delete file gretl2rc
- Compiling using *./configure --disable-sse2*
but my problem continue, I send us message from my console
Couldn't read /home/hebert/.gretl2rc
get_gretl_charset: using UTF-8
Descomprimiendo 146981 bytes de los datos...
Thank you for your time, but what can I do to solve this problem?
Hebert Suarez Cahuana
Departamento de Economía
Universidad Nacional de San Agustín
Although there is an extremely helpful and informative page online regarding the installation of Gretl on a Mac, Gretl does not want to work on my system as well as the Apple products of a few of my classmates. We all have downloaded the appropriate software (X11, GTK, etc.) and I have tried both the latest release of the product as well as the current snapshot but neither seem to work. Once the software is downloaded and dragged into the applications section (which normally installs most software automatically), I attempt to open Gretl and instead of opening, the program immediately terminates. Any suggestions?
ols d1 const d2 and the std error of d2 is 0.351919
Use s = sqrt[ ∑ ((e_i)^2/(n-2)) / (∑ (x_i - xbar)^2) ] for manually calculating the std error and the value is 0.88583 and does not match the one on gretl
What are the proper steps to do the manual calculating ?
Dear gretl community,
I am using gretl 1.7.4 under MS-Windows XP (Service Pack 2). My issue and question is the following:
When using the gretl editor to write a piece of code, I have to split a command over several lines. Specifically, with a panel dataset, I need to restrict the sample by just keeping a small number of the firms included in the full dataset. I tried to do this in various ways, but only one way appears to be feasible, as follows:
% code snippet begin ----
smpl --restrict firm=2 || \
firm=5 || \
% code snippet end ----
My problem is that my subsample will contain many more than just 3 firms (over 30 firms, that is), and when I code this in the way demonstrated above and run the code, gretl unfortunately does not restrict the sample exactly as I say in the code. Specifically, (a) firms appear in the subsample which are unwanted (like in the above example, having firm 17 in it), and also, (b) some firms I want to have are missing (like in the above example, not having firm 5 in it).
I understand that the gretl character for splitting commands over several lines is the "\" character. However, in my case at least, it seems that when the number of lines over which the splitting takes place is larger, the command may not work properly.
Could anyone of you provide an idea what may be going on or an idea how to solve resp. work around this problem, please? I'd appreciate this very much.
Many many thanks in advance.
Using 4 data point
The std error of sqft on gretl is 0.112376
Using the formula
s = sqrt[ ∑ ((e_i)^2/(n-2)) / (∑ (x_i - xbar)^2) ]
x_i = the ith observation
e_i = the ith error = y_i - yhat_i
n = sample size
xbar = mean of the x values