modified plot4