function y_vis = sim_pred(design,N,rho)
%simulate Hartford et al. problem, return y_vis for deepIV

% simulate data for this design
[f,sim,x_vis,~]=get_design(design);
[x,y,z]=sim(f,N,rho);

csvwrite('df_in.csv',[x y z]);
csvwrite('df_vis.csv',x_vis);

% run python script to obtain y_vis
python('deepIV_pred.py');
y_vis=csvread('df_out_unbiased.csv');

end

