removing nan and inf from a matrix
by Logan Kelly

Hello,
I need to take the log difference of a matrix, i.e. log(M[2 rows(M):,]/M[1:rows(M)-1,]). Unfortunately, M has elements equal to zero. I need to replace the nan's and inf's with 0's. This almost works
M = isnan(M) ? 0 : M
but does not remove inf's. Any sugestions?
4 years, 11 months

Forecasting variance of a GARCH model
by Karthik Raju

Hello,
I am writing to seek help to forecast volatility of index returns using
GRETL.
In GRETL, I want to know how to perform in the sample and out of sample
forecasting after estimating index return series by using GARCH variants
in the gig package.
Thank you.
Best,
Karthik
6 years, 1 month

bivariate probit in a loop
by Artur Bala

Dear all,
I'm currently estimating a bootstraped bivariate probit through a
progressive loop and retrieve each time the $yhat matrix. At some point,
the execution is interrupted with the "warning":
The statistic you requested is not available
>> genr series predict_external = $yhat[,1]
Is there a perfect prediction symptom behind this message isn't it?
Can one, in such a loop, skip cases where the MLE estimation is not
technically possible?
Best,
Artur
6 years, 3 months

Nested Logit
by David van Herick

Does anyone know if it is possible to run a nested logit model in gretl?
It seems it must be possible somehow with a hansl script or something, but
I can't seem to figure it out. I am hoping for an FIML version, but would
be happy to even find something that will do a two-step LIML version with
multinomial logit models that include logsum parameters.
6 years, 5 months

Possible redundancy of some function packages?
by Sven Schreiber

Hi everybody,
I'm wondering whether some of the function packages are still needed,
because sometimes it looks as if the same functionality is already built
into gretl. Here's a quick list in random order:
1) "clustered_ols" by Claudia Pigini. In what way is this different from
the built-in "ols ... --cluster=xyz"?
2) "cnumber" by Monsueto, S.E -- Here I don't think it's redundant but
I'm not getting the same results as with other code that should (?) be
equivalent. Consider this example and please explain why the results are
different:
<hansl>
include cnumber.gfn
open greene12_1.gdt
matrix X = {age, income, expend}
cnumber (X)
l = eigensym(X'X, null) # lines taken from Allin's email
CN = maxc(l)/minc(l) #
printf "CN = %g, (square root = %g)\n", CN, sqrt(CN)
</hansl>
3) "fgls" by Yi-Nung Yang: the help just says feasible GLS which is very
vague and generic; in what way is this different from gretl's "hsk" or
"wls" commands? If it is different, I would suggest to make the help
text more informative.
4) "GHegy" by Ignacio Díaz-Emparanza and "HEGY_test" by Jack Lucchetti.
Could you guys perhaps consolidate these?
5) "HoltWinters" by Ignacio Díaz-Emparanza. This sounds a lot like it's
also done by the "fcModels" package by Yi-Nung Yang. Is this true?
6) "JB" by Yi-Nung Yang. This does a Jarque-Bera test and even the help
text mentions that it is built into gretl (as "normtest ... --jbera").
So it's not obvious to me what the purpose of the package is.
7) "MWU" and "mwu" by Yi-Nung Yang. AFAICS the only difference is
whether you pass the arguments as series or as vectors (matrices). This
may be a matter of taste, but personally I would suggest that you choose
which is the interface of your function, i.e. series or matrices, and
then the user/caller will have to follow that rule, and the other
package with the other interface would be gone.
And with respect to "mwu_dummy", this is even more of a personal taste
thing, but perhaps you could consolidate all this into one function, for
example by introducing a third function parameter with a default value:
"function void mwu(series x, series y, int dummy[0])"
So to do what "mwu_dummy()" does now you would pass your 'group'
variable as y, and call the function with dummy=1.
Thanks,
sven
6 years, 5 months

Running gretlcli on Mac OS X
by Berend Hasselman

If I want to execute the commandline gretl on OS X will this suffice (in a terminal of course)?
/Applications/Gretl.app/Contents/Resources/bin/gretlcli <any options>
Berend
6 years, 5 months

join command - syntiax
by guido

Hi all
I am sorry tho ask help. Before asking here i studied the newest copy of the Guide, sought in the list whitout result.
I am surely making a trivial mistake using "join" command but i am unable to bypass it by myself.
I want to join variable CHIUSURA in a2.gdt, with a1.gdt
a1.gdt
obs ch1
2014-01-02 0,8000
2014-01-03 0,8425
2014-01-06 0,8485
2014-01-07 0,9060
2014-01-08 0,8790
2014-01-09 0,8660
2014-01-10 0,8370
2014-01-13 0,8690
2014-01-14 0,8625
2014-01-15 0,8560
a2.gdt
obs CHIUSURA
2014-01-02 19,97
2014-01-03 21,40
2014-01-06 22,08
2014-01-07 21,55
2014-01-08 21,81
2014-01-09 21,49
2014-01-10 20,86
2014-01-13 21,00
2014-01-14 21,10
2014-01-15 21,00
this is the script
#open the left hand database
open /home/guido/gretl/Star/a1.gdt
#join the CHIUSURA var in a2.gdt
join /home/guido/gretl/Star/a2.gdt CHIUSURA
this is the output log
gretl versione 1.9.91
Sessione corrente: 2014-11-27 16:35
#open the left hand database
? open /home/guido/gretl/Star/a1.gdt
Lettura del file dati /home/guido/gretl/Star/a1.gdt
Periodicità: 5, oss. max.: 10
Intervallo delle osservazioni: 2014-01-02-2014-01-15
2 variabili elencate:
0) const 1) ch1
#join the CHIUSURA var in a2.gdt
? join /home/guido/gretl/Star/a2.gdt CHIUSURA
[Sorry, the command is not available for this estimator]
Errore nell'esecuzione dello script: abbandono
> join /home/guido/gretl/Star/a2.gdt CHIUSURA
Thx for any suggestion.
Guido
6 years, 5 months

BDS code for gretl
by José Belbute

Hello,
I wonder if it is available a BDS (Brock et all, 1996) test code for Gretl?
thank you
José M. M. Belbute,
6 years, 5 months

Random Effects Probit output
by Jan Tille

Dear Grelt list members,
I run a random effects probit regression and was wondering, why the output displays p-values, though the -p-values option was not selected. When I estimate the model as a pooled (panel) probit, then Gretl displays the slopes, which corresponds to the command description.
Is there another option (accessor variable, etc.) which enables one to retrieve the average marginal effects - averaged over each entity and instead of evaluating the effects at the average of the independent variables? I ask because I am using some binary independent variables, and evaluating the marginal effects at some value in between would not make much sense for these variables.
FYI the LR test that tests Ho: rho=0 is rejected with a p-value 0.000173
Thanks in advance.
Jan
6 years, 5 months

Favor: code of the TRAMO program
by Manuel Dario Hernandez Bejarano

Good morning.
My name is Dario Hernández, i am student of master in statistic of National
University of Colombia, i have been checking your main page and in this i
read that the codes are open-source software, i would like to get the codes
of TRAMO, this codes are very useful for my thesis, because of the
following reasons, first at all, this codes not only are based on the
paper of Gomez & Marraval 1994, which is very important for me, but also
are fundamental in order to understand how i can program the equations
that appear in Gomez & Marraval 1994.
I have already subscribed me at the mailing list.
I look forward to your answer!
Regards,
Dario Hernández
Student of master in Statistic
National University of Colombia
6 years, 5 months