support density
fixed comments by @sorribas
docs for density and pdf
add pdf enum