plot1: code cleaned up.