Dsample command

Dear all,

I have a little problem with dsample.

E.g. if I use it like:

// Adapted from Jesus Fernandez-Villaverde, Basic RBC Model with Monopolistic Competion Philadelphia, March 3, 2005

var y c k i l w r;
varexo z;
parameters beta psi delta alpha sigma epsilon;

alpha = 0.33;
beta = 0.99;
delta = 0.023;
psi = 1.75;
sigma = (0.007/(1-alpha));
epsilon = 10;

model;
(1/c) = beta*(1/c(+1))(1+r(+1)-delta);
psi
c/(1-l) = w;
c+i = y;
y = (k(-1)^alpha)(exp(z)l)^(1-alpha);
w = y
((epsilon-1)/epsilon)
(1-alpha)/l;
r = y*((epsilon-1)/epsilon)*alpha/k(-1);
i = k-(1-delta)*k(-1);
end;

initval;
k = 9;
c = 0.7;
l = 0.3;
w = 2.00;
r = 0.00;
z = 0;
end;

endval;
z = 0.1;
end;

steady;

check;

simul(periods=1000);
dsample 60;
rplot k;

the the figure I obtain is not for the first 60 periods but for 1000 periods.

I try to reduce the time window. However, I get neither an error message nor does matlab display the desired figure.

Best

Chris

Hi

In Dynare 4.0.2 the dsample command is buggy. It will be fixed in the coming 4.0.3 release.

Sébastien

Thank you.

So I’ll try it with an older version.

Best regards,

Chris

Hi Sebastien.

I am using Dynare 6.2 and when I use the command dsample I get the error message “Unrecognized function or variable ‘dsample’.”

This is the end of my code:

perfect_foresight_setup(periods=300);
perfect_foresight_solver;
dsample 250;
options_.rplottype=2;
rplot X Y Z;

According to the Dynare Reference Manual Version 6, the dsample command is still available.

Thanks for any hints!

Best, Dominik

That is a bug. I erroroneously removed the file in Remove unused dsample.m and mcompare.m (af274aec) · Commits · Dynare / dynare · GitLab
The bug will be fixed in Dynare 6.3. For now, you could simply download the file again.

1 Like