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