script for plot 4 added