modified top_bot_plot in plot_data