Description Usage Arguments Details Author(s) References Examples
The fuction ZMPL() defines the ZMPL distribution, a two paramenter
distribution. The zero modified Poisson-Lindley distribution is similar
to the Poisson-Lindley distribution but allows zeros as y values. The extra parameter
models the probabilities at zero. The functions dZMPL, pZMPL, qZMPL and rZMPL define
the density, distribution function, quantile function and random generation for
the zero modified Poisson-Lindley distribution.
plotZMPL can be used to plot the distribution. meanZMPL calculates the expected
value of the response for a fitted model.
1 2 3 4 5 6 |
theta |
theta parameter values |
p0 |
p0 parameter values |
x, q |
vector of observations/quantiles |
log, |
log.p logical; if TRUE, probabilities p are given as log(p). |
lower.tail |
logical; if TRUE (default), probabilities are P[X <= x], otherwise, P[X > x] |
p |
vector of probabilities. |
n |
number of observations. If |
from |
where to start plotting the distribution from |
to |
up to where to plot the distribution |
... |
other graphical parameters for plotting |
The probability massa function of the is given by
f_{X}(x;θ,p0) = p0 + (1-p0)*P[Y=0] I(y=0) + (1-p0)*P[Y>0] I(y>0)
where
P[Y=y]
is a probability massa function of the Poisson-Lindley distribution.
Manoel Santos-Neto mn.neco@gmail.com, Marcelo Bourguignon m.p.bourguignon@gmail.com, Danillo Xavier danilloxavier@gmail.com and Vera Tomazella vera@ufscar.br
Bourguignon, M., Xavier, D., Santos-Neto, M., Tomazella, V. (2017) The Modified Poisson-Lindley distribution: A model for overdispersed and underdispersed count data. manuscript.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | FIZMPL()
theta <- seq(0.05,1,l=100)
aux0 <- - ((theta^2)*(theta+2)/( (theta^2) +3*theta+1) )
p0 <- seq(0,1,l=100)
g <- expand.grid(x = theta, y = p0)
z <- FIZMPL(theta,p0)
z[z<0] <- 0
g$z <- z
print(wireframe(z ~ x * y ,g, xlab=expression(theta), scales = list(arrows = FALSE), ylab=expression(pi), zlab = "FI(X)") )
theta <- seq(0.05,1,l=100)
aux0 <- - ((theta^2)*(theta+2)/( (theta^2) +3*theta+1) )
p0 <- seq(min(aux0),0,l=100)
g <- expand.grid(x = theta, y = p0)
z <- FIZMPL(theta,p0)
z[z<0] <- 0
g$z <- z
print(wireframe(z ~ x * y ,g, xlab=expression(theta), scales = list(arrows = FALSE), ylab=expression(pi), zlab = "FI(X)") )
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.