Adding code for plot1