plot.npnorm | R Documentation |
Function plot.npnorm
plots the normal mixture.
## S3 method for class 'npnorm'
plot(
x,
mix,
beta,
breaks = NULL,
col = 2,
len = 100,
add = FALSE,
border.col = NULL,
border.lwd = 1,
fill = "lightgrey",
main,
lwd = 2,
lty = 1,
xlab = "Data",
ylab = "Density",
components = c("proportions", "curves", "null"),
lty.components = 2,
lwd.components = 2,
...
)
x |
an object of class |
mix |
an object of class |
beta |
the structural parameter. |
breaks |
the rough number bins used for plotting the histogram. |
col |
the color of the density curve to be plotted. |
len |
the number of points roughly used to plot the density curve over the interval of length 8 times the component standard deviation around each component mean. |
add |
if |
border.col |
color for the border of histogram boxes. |
border.lwd |
line width for the border of histogram boxes. |
fill |
color to fill in the histogram boxes. |
main , lwd , lty , xlab , ylab |
arguments for graphical parameters
(see |
components |
if |
lty.components , lwd.components |
line type and width for the component curves. |
... |
arguments passed on to function |
Yong Wang <yongwang@auckland.ac.nz>
Wang, Y. (2007). On fast computation of the non-parametric maximum likelihood estimate of a mixing distribution. Journal of the Royal Statistical Society, Ser. B, 69, 185-198.
nnls
, cnm
,
cnmms
, plot.nspmix
.
mix = disc(pt=c(0,4), pr=c(0.3,0.7)) # a discrete distribution
x = rnpnorm(200, mix, sd=1)
plot(x, mix, beta=1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.