some changes for plot script