print("Plotting total histogram") hist1 = histogram_plot(results, distance=d, frac=100) hist1.savefig( os.path.join(figPath, 'full_histogram_{}.png'.format(DATASET)), bbox_inches='tight') print("Plotting fraction histogram") hist2 = histogram_plot(results, distance=d, limit=lim) hist2.savefig( os.path.join( figPath, 'tol_{}_histogram_{}.png'.format(str(lim).replace('.', '_'), DATASET)), bbox_inches='tight') print("Considering {} lowest values".format(lim)) # print("Generating scatter plot") # scatter_dist_plot(results, params, tolerance=tol, n_ticks=4) print("Generating KDE plot") g = kde_plot(results, params, limit=lim, n_ticks=4, d=d, median_file=os.path.join(figPath, "medians.txt")) g.fig.savefig( os.path.join(figPath, 'PLOS_{}_{}_{}_kde.png' .format(DATASET, str(lim).replace('.', '_'), d)), bbox_inches='tight') print("Generating averaged time series plot") config["offset"] = {} # for t in config["targets"]: # config["offset"]["{}_offset".format(t)] = d0[t][0] try: fig, ax = plot_repeated_outputs(results, n_repeats=25, limit=lim, distance=d, **config) fig.set_size_inches(18.5, 12.5) fig.savefig( os.path.join(figPath, 'PLOS_{}_{}_{}_TS.png' .format(DATASET, str(lim).replace('.', '_'), d)),
hist1.savefig(os.path.join(figPath, 'full_histogram_experimental.png'), bbox_inches='tight') print("Plotting fraction histogram") hist2 = histogram_plot(results, distance=d, tolerance=tol) hist2.savefig(os.path.join( figPath, 'tol_{}_histogram_experimental.png'.format( str(tol).replace('.', '_'))), bbox_inches='tight') print("Considering {} lowest values".format(tol)) # print("Generating scatter plot") # scatter_dist_plot(results, params, tolerance=tol, n_ticks=4) sorted_results = results.sort_values(by=d).head(5000) print("Generating KDE plot") g = kde_plot(sorted_results, params, tolerance=tol, n_ticks=4, d=d, median_file=os.path.join(figPath, "medians.txt")) g.fig.savefig(os.path.join( figPath, 'PLOS_experimental_{}_{}_kde.png'.format( str(tol).replace('.', '_'), d)), bbox_inches='tight') print("Generating averaged time series plot") config["offset"] = {} for t in config["targets"]: config["offset"]["{}_offset".format(t)] = d0[t][0] fig = plot_repeated_outputs(results, n_repeats=25, tolerance=tol, distance=d, **config)