
addpath c:\dynare\4.6.3\matlab
clear all
close all
clc
std_y=[];
rho = 0.5:0.05:1;
first_time = 1;
%dynare mymodel
for ii=1:length(rho)
    if first_time      
        dynare mymodel noclearall;
        set_param_value('rho_a',rho(ii));
        first_time = 0;
        std_y(ii)=sqrt(oo_.var(1));
    else
        set_param_value('rho_a',rho(ii));
        info = stoch_simul(M_, options_, oo_, var_list_);
        std_y(ii)= sqrt(oo_.var(1));
        if info
          disp('Computation fails for rho = ', num2str(rho_a));
        end
    end
end

plot(rho,std_y)

