% Miscellaneous code for tables and figures

****
 outfile_name = [outdir 'aaa.csv'];
 fileID = fopen(outfile_name,'w');
 fprintf(fileID,'num,sector,mean,se_mean,stddev,,ym50,ym60,ym70,ym80,ym90,ym00_end \n');
 prtmat_comma(xx,fileID,'%5.2f','\n');

****
set(gcf, 'Position', get(0, 'Screensize'));  % Full Screen
fig_str = ['Factor_Cross_autocorrelations_' suf]; str_fig = [figdir fig_str]; saveas(gcf,[str_fig '.png']);

***
figure;
        for iplot = 1:n_cs;
           subplot(4,n_cs,iplot);
           bar(x,nw_uhatx_s(:,iplot),w1,'b');
           hold on;
              bar(x,nw_ux_s(:,iplot),w2,'w');
           hold off;
           ax = gca;
           ax.FontSize = ax_fs;
           ylim([x1 y1]);
           set(gca,'xticklabel',[]);
           if iplot == 1;
               legend('Newey-West size distortion','Newey-West size distortion (null imposed)');
           end;

****
