# The Old Faithful geyser data
d <- density(faithful$eruptions, bw = "sj")
> head(d$x)
[1] 1.179869 1.188363 1.196857 1.205350 1.213844 1.222338
I'm using density
function in {stats}
, and I'm wondering if it's possible to see density at specific values in the output? For example, currently, I have density estimates at eruption values of [1] 1.179869 1.188363 ...
but what if I want to know the density estimates at eruption values 1 2 5 10 ...
? Is there a way to extract these the density
object, d
?