function printout(reps,out_ticker,MaxDup,contrib_out,prey_num,runique, Lmax) % generate results table for pop-up message box... %__________________________________________________________________________ S1=(' %%%%% DIAGNOSTICS AND RESULTS %%%%%'); lnspace=(' ');%line spacer aa = ['How many thousands of iterations carried out?: ', num2str(reps)]; S1 = strvcat(S1,lnspace,aa); aa=('Does the number of iterations seem appropriate?'); S1 = strvcat(S1,lnspace,aa); if out_ticker > 1000 aa=[' Probably! - there are ',num2str(out_ticker), ' posterior draws (more than 1000)']; else aa=[' Probably not! - there are ',num2str(out_ticker), ' posterior draws (less than 1000)']; end S1 = strvcat(S1,aa); if MaxDup < 2 aa=[' Probably! - there are no duplicate draws in the posterior chain']; else aa=[' Probably not! - a single posterior draw has been duplicated ',num2str(MaxDup), ' times in the posterior chain']; end S1 = strvcat(S1,aa,lnspace); %put one line spacers here on concat... then aa =['unique parameter vectors in resample = ',num2str(runique),' out of ' num2str(out_ticker)]; S1 = strvcat(S1,aa); aa = ['ratio between the posterior at the best draw, and the total posterior density is ', num2str(Lmax)]; S1 = strvcat(S1,aa); aa = (' **NOTE- this ratio should be less than .01'); S1 = strvcat(S1,aa,lnspace,lnspace); %ut two line spaces here on concat... then aa = ('Value at each percentile of the posterior proportional contribution of each source (median values @ 50%):'); S1 = strvcat(S1,aa,lnspace); aa= ('5% 25% 50% 75% 95%'); S1 = strvcat(S1,aa); aa=('---------------------------------------------------------------------------'); S1 = strvcat(S1,aa); aa = (prctile(contrib_out,[5 25 50 75 95])'); % a useful summary of x aa = num2str(round(aa.*1000) /1000); %rounds to 3 decimal places S1 = strvcat(S1,aa,lnspace,lnspace); msgbox(S1,'Model Run Results');