x <- rgev(1e5, 5, 2, .5)
xx <- seq(0, 1000, by = 0.1)
hist(x, 1000, freq = FALSE, xlim = c(0, 50))
lines(xx, dgev(xx, 5, 2, .5), col = "red")
hist(pgev(x, 5, 2, .5))
plot(ecdf(x))
lines(xx, pgev(xx, 5, 2, .5), col = "red", lwd = 2)
Run the code above in your browser using DataLab