Add density option to dplot.py