Adds density plotting matlab function