plot-distributionH | R Documentation |
A plot function for a distributionH
object. The function returns a representation
of the histogram.
## S4 method for signature 'distributionH'
plot(x, type = "HISTO", col = "green", border = "black")
x |
a |
type |
(optional) a string describing the type of plot, default="HISTO". |
col |
(optional) a string the color of the plot, default="green". |
border |
(optional) a string the color of the border of the plot, default="black". |
## ---- initialize a distributionH
mydist <- distributionH(x = c(7, 8, 10, 15), p = c(0, 0.2, 0.7, 1))
# show the histogram
plot(mydist) # plots mydist
plot(mydist, type = "HISTO", col = "red", border = "blue") # plots mydist
plot(mydist, type = "DENS", col = "red", border = "blue") # plots a density approximation for mydist
plot(mydist, type = "HBOXPLOT") # plots a horizontal boxplot for mydist
plot(mydist, type = "VBOXPLOT") # plots a vertical boxplot for mydist
plot(mydist, type = "CDF") # plots the cumulative distribution function of mydist
plot(mydist, type = "QF") # plots the quantile function of mydist
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.