I’m sorry, Sven, but as you can see, I did start a new thread.
As I said before, I have a need to loop through quit a few .gretl files I get from my
students and to find something inside each of them, for example model outputs saved in the
.gretl files.
I can’t do loops with .gretl files like I do with .gdt files.
Here is a sample script:
<hansl>
string path = "/Users/fred/Documents/UIBE/22-1/ECON301/Data4Students/"
string studentnames = path ~ "names.txt"
string namesread = readfile(studentnames)
strings anames = strsplit(namesread,"\n")
loop i=1..nelem(anames)
string fname = anames[i]
dataname = "@path@fname.gretl"
open \
@dataname #--preserve --quiet
scalar incomecoeff = model_income.$coeff[2]
# do something here with what I found, for example.
endloop
</hansl>
As I tried to figure out why, instead of looping .gretl files, if I just using a script to
open one of them, there is a message about: “Opening a new session file will automatically
close the current session. Any unsaved work will be lost. Proceed to open session file?”
There seems to be no way to turn off this warning, so the script gets hang on this warning
message.
Any suggestion?
Fred
Date: Sun, 19 Jun 2022 18:26:54 +0200
From: Sven Schreiber <svetosch(a)gmx.net>
Subject: [Gretl-users] Re: Not able to open .gretl session files in a
loop
To: gretl-users(a)gretlml.univpm.it
Message-ID: <b6ddf599-8dfa-e95d-1d7d-bbaa4f0f21ca(a)gmx.net>
Content-Type: text/plain; charset=UTF-8; format=flowed
Am 18.06.2022 um 01:40 schrieb Fred Engst:
> Hi Allin and all,
Fred, first of all please start a new thread when you start a new topic,
do not reply to an unrelated one.
> I have a need to loop through quit a few .gretl files, but found that I can’t do that
like I do with .gdt files.
Please be more specific what you mean by "can't do".
cheers,
sven
------------------------------
Subject: Digest Footer
_______________________________________________
Gretl-users mailing list -- gretl-users(a)gretlml.univpm.it
To unsubscribe send an email to gretl-users-leave(a)gretlml.univpm.it
Website:
https://gretlml.univpm.it/postorius/lists/gretl-users.gretlml.univpm.it/
------------------------------
End of Gretl-users Digest, Vol 185, Issue 12
********************************************