implementation of all the plots