updated plot3 and plot4