Am 27.04.20 um 13:10 schrieb Alecos Papadopoulos:
I have a question for more experienced users and the guardians of
gretl.
I am about to go into Markov Chain Monte Carlo simulations and an
acceptance/rejection algorithm of the generated values. This would
require something like 200,000 loop runs, from which say something like
100,000 will be accepted and should be stored. The number of parameters
is 32.
Up to now with smaller simulations, I used to store such values in
matrix objects, and then turn them into series objects. But now I am
looking at a 100,000 X 32 matrix, or at best at 32 vectors of 100,000 X
1 dimension, and I was wondering whether such a large row dimension will
create problems of speed or any other kind of problems.
Any suggestion on that?
Hi Alecos,
Regarding the speed problem: I would say, it depends on what you want to
do. Computing column-wise statistics such as mean through the meanc()
function won't be a problem I guess. Sorting will be costly of course.
If you put your code into functions, make use of pointers to avoid
actual copying of big matrices.
Also memory won't be an issue: Gretl stores matrix in double-precision
format. Each float is of size 8 byte. Thus, the matrix will consume
<(100000 * 32 * 8) / 1024 / 1024 = 24.4 MB>.
Artur