montecarlo {agricolae} | R Documentation |
Random generation form data, use function density and parameters
montecarlo(data, k, ...)
data |
vector or object(hist, graph.freq) |
k |
number of simulations |
... |
Other parameters of the function density, only if data is vector |
Generates random.
Felipe de Mendiburu
library(agricolae) r<-rnorm(50, 10,2) montecarlo(r, k=100, kernel="epanechnikov") # other example h<-hist(r,plot=FALSE) montecarlo(h, k=100) # other example breaks<-c(0, 150, 200, 250, 300) counts<-c(10, 20, 40, 30) h<-graph.freq(x=breaks,counts=counts,plot=FALSE) montecarlo(h, k=100)