Description Usage Arguments Value References Examples
This method determines the optimal scale parameter of the Pareto distribution using the iterative method \insertCiteclauset2009powerdistributionsrdthat minimizes the Kolmogorov-Smirnov distance.
1 | clauset.xmin(x, q = 0)
|
x |
data vector |
q |
Percentage of data to search over (starting from the largest values) |
Returns a named list containing a
Named vector of coefficients
Minimum Kolmogorov-Smirnov distance
Number of observations in the Pareto tail
Evolution of the Pareto shape parameter over the iterations
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ## Determine cuttof from compostie lognormal-Pareto distribution using Clauset's method
dist <- c("lnorm", "pareto")
coeff <- c(coeff1.meanlog = -0.5, coeff1.sdlog = 0.5, coeff2.k = 1.5)
x <- rcomposite(1e3, dist = dist, coeff = coeff)
out <- clauset.xmin(x = x)
out$coefficients
coeffcomposite(dist = dist, coeff = coeff, startc = c(1, 1))$coeff2
## Speed up method by considering values above certain quantile only
dist <- c("lnorm", "pareto")
coeff <- c(coeff1.meanlog = -0.5, coeff1.sdlog = 0.5, coeff2.k = 1.5)
x <- rcomposite(1e3, dist = dist, coeff = coeff)
out <- clauset.xmin(x = x, q = 0.5)
out$coefficients
coeffcomposite(dist = dist, coeff = coeff, startc = c(1, 1))$coeff2
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.