e_n_q | R Documentation |
Expected value of n^q
when n
follows a Poisson distribution
of parameter n
.
e_n_q(n, q)
n |
A positive integer vector. |
q |
A positive number. |
The expectation of n^q
when n
follows a Poisson distribution
was derived by \insertCiteGrassberger1988;textualdivent.
It is computed using the beta function.
Its value is 0 for n-q+1<0
, and close to 0 when n=q
,
which is not a correct estimate: it should not be used when q > n
.
A vector of the same length as n containing the transformed values.
n <- 10
q <- 2
# Compare
e_n_q(n, q)
# with (empirical estimation)
mean(rpois(1000, lambda = n)^q)
# and (naive estimation)
n^q
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.