added functionality for scatplot matrix