Gretl project on the launchpad
by Ivan Sopov
Hello, gretl developers.
I'm trying to start a translation of help files into russian on
launchpad.net as it seems to be the most suitable tool to participate
for all familiars with econometrics but not with gettext, linux. cvs,
etc.
The problem is that there is already a project for gretl on launchpad
and it is strongly prohibited to start more than one project for a
single program. I cannot contact with Constantine Tsardounis for about
a month, so I think it is time to re-assign that project to someone
else. On the irc-channel of launchpad I was told that
Our admins can re-assign the project to new owners but we'd prefer to
hear from the upstream owners. can you get one of them to submit a
question here:
https://answers.edge.launchpad.net/launchpad
But if nobody from main developers wants to register and do something
at launchpad it is possible to assign this function to me and in that
case a letter in this list will probably be enough.
I have prepared a .po-file for genr_funcs.xml and gretl_commands.xml
with the help of po4a utility and got 1511 strings for translation
(strings a rather big).
Good luck, Ivan Sopov.
P.S. My previous letter about using launchpad for translation is
http://lists.wfu.edu/pipermail/gretl-devel/2009-November/002171.html
12 years, 1 month
"null" default for list arguments in function package
by Sven Schreiber
Hi,
as I'm debugging and trying to adapt the mentioned function package for
permanent-transitory decompositions I will probably be sending a couple
of emails with bug reports. (Also in spirit with the call for reporting
function packaging bugs at the conference.)
Ok, so here we go:
I have the following (example) function which specifies a "null" default
for an optional list argument:
function scalar defaultnullcheck(const list mylist[null])
print "nothing happening"
end function
If I package that function and call it in the GUI I don't get the "null"
default inserted in the place for the mylist argument. Instead another
list (probably the first that was created in the session) is inserted
there. I propose to insert the "null" keyword instead.
cheers,
sven
13 years, 4 months
'smpl' in loop in function
by Sven Schreiber
Hi,
so I'm trying to make my function package work both with sub-sampled and
full-sampled data. This is not so easy because of gretl's behavior to
use pre-sample data for VAR/VECM estimation, if such data is available.
This means that the two cases (sub-sampled or not) have to be handled
differently. (IMHO this is bad, BTW, so taking up the issue which was
already discussed before, I still vote to always *prevent* gretl from
reaching back to pre-sample values.)
Anyway, so to deal with this issue I am using a couple of 'smpl'
shortening and re-enlarging commands in my functions, similar to the
following example:
<hansl>
function void samplecheck(int p)
smpl +p +0
loop 30
smpl -p +0
smpl +p +0
end loop
end function
samplecheck(3)
</hansl>
But I get an error message:
"Unrecognized sample command
*** error in function samplecheck"
Note that everything works fine if I don't use a loop in the example, so
the error message must be misleading.
thanks,
sven
13 years, 4 months
transitory components
by Sven Schreiber
Hi,
here's a prototype of the function package that does what I presented at
the conference. I think I have finally managed to add enough 'smpl'
commands here and there such that it should work for full-sample and
sub-sampled datasets.
This does not (yet) use bundles, but it still requires a very recent cvs
build / snapshot (e.g. due to the clash with the formerly allowed smpl
short-form options).
Also, I think some parts could be simplified using the recent $vecGamma
accessor, but as it works the way it is now I see no urgent reason to
change that.
Testing is welcome, please post comments on this list. Expect bugs, as I
said this is a prototype, although there are no known issues. There are
two public functions from which you get to choose: getBootout,
getDeltaout. The first does two different bootstraps, the second uses
the delta method. Actually, since the delta method is so fast I guess it
could always be done and then, instead of choosing between the two
public functions, one would instead get a tick box for deciding whether
or not to run the (somewhat time-consuming) bootstrap as well.
BTW, maybe there should be a pre-defined place to state the license of a
function package. Or is that in the mysterious spec file or somewhere
where I missed it?
thanks,
sven
13 years, 4 months
freeze on loading functions
by Sven Schreiber
Hi,
here's what I did:
- look on package server to install 'BreitungCandelonTest' -- ok
- afterwards (after executing that first package) create a totally
unrelated new package and save it in a non-default location
- then navigate with the local function package management window to
the directory where I just saved the new package (formally: to look for
other packages locally)
- then in the package management window those additional local packages
are visible, but nothing can be done, gretl is frozen (have to kill it)
I suspect it's because in the local directory there is a copy (exact or
not I'm not sure right now) of the package 'BreitungCandelonTest' which
was installed from the server before. Seems like the two versions clash.
(Just speculating, though.)
thanks,
sven
13 years, 4 months
Responses to Sven, I
by Allin Cottrell
Here are responses to some of the points made by Sven over the last few
days. More to come.
Sven (1):
I have the following (example) function which specifies a "null" default
for an optional list argument:
function scalar defaultnullcheck(const list mylist[null])
print "nothing happening"
end function
If I package that function and call it in the GUI I don't get the "null"
default inserted in the place for the mylist argument. Instead another
list (probably the first that was created in the session) is inserted
there. I propose to insert the "null" keyword instead.
Allin: OK, done in CVS.
Sven (2):
'string' and 'bundle' are not syntax-colored (nor "eval")
Allin: should now be OK in CVS.
Sven (3):
When I specify a function parameter with min/max and default values like
this:
'int p[1::2]',
on saving gretl seems to insert a trailing colon:
'int p[1::2:]'
This doesn't seem to do any harm (which is also strange, isn't it?), but
is it intended?
Allin: This is not really a problem: the last colon demarcates the
(possibly absent) "step" value. But it's maybe inelegant, and is
now removed in CVS.
Sven (4):
So I've noticed that when I use Alt+Tab to cycle through the open
windows (on Ubuntu, haven't tried windows) the main gretl window and any
gretl script windows are marked with the gretl logo/icon, but not the
function package list, or the function package call window. This makes
it a little difficult to quickly switch to them.
Allin: this should be fixed in CVS.
Sven (5):
Is it intended that the following doesn't work:
<hansl>
function void check(void)
print "yeah"
end function
eval check()
</hansl>
In contrast, 'eval mnormal(1,1)' of course works.
Allin: I would say it's reasonable that the above doesn't work:
there's nothing to "evaluate" here, since the function doesn't
return anything. Just say "check()".
Sven (6):
<hansl>
function void samplecheck(int p)
smpl +p +0
loop 30
smpl -p +0
smpl +p +0
end loop
end function
samplecheck(3)
</hansl>
But I get an error message:
"Unrecognized sample command
*** error in function samplecheck"
Allin: The problem here is not specific to loops, it's specific
to the use of "-p", which is a valid short-form option for the
"smpl" command. Fix in CVS: insist on long-form options for smpl
(i.e. don't interpret "-p" as an option flag).
13 years, 4 months
Possible manual reorganization
by Sven Schreiber
Some time ago it was asked whether the structure of the manual could be
optimized. Here's a suggestion which probably doesn't attain the optimum
but IMHO could be an improvement:
- Introduce a new part "Programming in gretl (a.k.a. introduction to
'hansl')". This part would (initially) consist of chapters 9 through 13
(maybe also 14).
- Convert chapter 12 (lists and strings) into sections of chapter 11
(data types). I also thought about doing the same with chapter 13
(matrices), but matrices are so important and chapter 13 so long that it
probably deserves to be left as is.
- move chapter 10 (functions) to the end of the new hansl part (i.e.
after what's now chapter 13 or chapter 14)
what do you think?
-sven
13 years, 4 months
local function packages list not persistent
by Sven Schreiber
Steps:
1) open the list with function packages on local machine
2) let gretl look in an additional directory to become aware of other
packages -> more packages appear in the window list
3) close the list window
4) re-open the list window, the additional packages have disappeared
I guess this isn't intended?
thanks,
sven
13 years, 4 months
GUI package call: assign return value "optional"
by Sven Schreiber
Hi,
next (small) issue:
In the GUI dialog for a function package call it says that specifying a
return variable is "optional". Technically it's true but IMHO a package
author should have an influence on the formulation there. For many
packages the main results will be in the returned variable, not in the
printout.
Or does the "spec" file have something to do with that?
thanks,
sven
13 years, 4 months
'eval' not for user-defined functions?
by Sven Schreiber
Is it intended that the following doesn't work:
<hansl>
function void check(void)
print "yeah"
end function
eval check()
</hansl>
In contrast, 'eval mnormal(1,1)' of course works.
thanks,
sven
13 years, 4 months