Description Usage Arguments Details Author(s) See Also Examples
Create a 2d image or contour plot of the density, intensity or any image object.
For examples see
http://faculty.missouri.edu/~micheasa/sppmix/sppmix_all_examples.html#plot_density
1 2 |
density_df |
A data frame. Typically density_df=as.data.frame(imdens), where imdens an |
contour |
Logical flag requesting the countour plot only. |
grayscale |
Plot in gray scale. Default is FALSE (use colors). |
pp |
Optional point pattern to display (a |
surf |
Optional |
ppsize |
Size of the points in the plot. |
main |
A title for the 2d plot. |
This function does not open a new window for the plot.
Sakis Micheas
1 2 3 4 5 6 7 8 | # plot a mixture of normals density
truemix <- rnormmix(m = 3, sig0 = .1, df = 5, xlim= c(0, 5), ylim = c(0, 5))
summary(truemix)
normdens=dnormmix(truemix, xlim = c(0, 5), ylim = c(0, 5))
#2d plots
plot_density(normdens, main="2d mixture density plot\nWindow=[0,5]x[0,5]")
#Contour plot
plot_density(normdens, contour=TRUE, main="2d mixture contour plot\nWindow=[0,5]x[0,5]")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.