updated plot 1 code, finished plot 2 and 3