Last chance! 50% off unlimited learning
Sale ends in
fitPareto(x, k = NULL, x0 = NULL, method = "thetaPDC",
groups = NULL, w = NULL, ...)
thetaPDC
(the default). See
x
(e.g., households). If
supplied, each group of observations is expected to have
the same value in x
(e.g., household income).
Only the values of every fk
and x0
of course correspond
with each other. If k
is supplied, the threshold
x0
is estimated with the $n - k$ largest value
in x
, where $n$ is the number of observations.
On the other hand, if the threshold x0
is
supplied, k
is given by the number of observations
in x
larger than x0
. Therefore, either
k
or x0
needs to be supplied. If both are
supplied, only k
is used (mainly for back
compatibility).
The function supplied to method
should take a
numeric vector (the observations) as its first argument.
If k
is supplied, it will be passed on (in this
case, the function is required to have an argument called
k
). Similarly, if the threshold x0
is
supplied, it will be passed on (in this case, the
function is required to have an argument called
x0
). As above, only k
is passed on if both
are supplied. If the function specified by method
can handle sample weights, the corresponding argument
should be called w
. Additional arguments are
passed via the ...paretoTail
, replaceTail
thetaPDC
, thetaWML
,
thetaHill
, thetaISE
,
thetaLS
, thetaMoment
,
thetaQQ
, thetaTM
data(eusilc)
## gini coefficient without Pareto tail modeling
gini("eqIncome", weights = "rb050", data = eusilc)
## gini coefficient with Pareto tail modeling
# using number of observations in tail
eqIncome <- fitPareto(eusilc$eqIncome, k = 175,
w = eusilc$db090, groups = eusilc$db030)
gini(eqIncome, weights = eusilc$rb050)
# using threshold
eqIncome <- fitPareto(eusilc$eqIncome, x0 = 44150,
w = eusilc$db090, groups = eusilc$db030)
gini(eqIncome, weights = eusilc$rb050)
Run the code above in your browser using DataLab