small changes on plots and useful functions...