Description Usage Arguments Details Value References Examples
Basic data envelopment analysis to replace rDEA::dea due to difficulties installing rDEA on travis-ci
1 | dea(XREF, YREF, X, Y, model = "output", RTS = "variable")
|
XREF |
Matrix of inputs for observations used for constructing the frontier |
YREF |
Matrix of outputs for observations used for constructing the frontier |
X |
Matrix of inputs for observations, for which DEA scores are estimated |
Y |
Matrix of outputs for observations, for which DEA scores are estimated |
model |
Orientation of the model; must be "input" or "output" |
RTS |
Returns-to-scale for the model; must be "constant", "non-increasing" or "variable" |
This function estimates efficiency using data envelopment analysis. The linear program is constructed as in Fare et al. (1985) and optimized using lpSolve::lp. The function was built to swap with rDEA::dea because installation of rDEA presented problems for travis-ci, due to difficulties installing glpk. Should installation of rDEA on travis-ci become possible, this function will be removed.
Returns a list with the following components
thetaOpt |
A vector of efficiency estimates, in [0, 1] interval |
lambda |
A matrix of constraint coefficients |
lambda_sum |
A vector of sum of lambdas; lambda_sum = 1 for variable RTS, lambda_sum <= for non-increasing RTS |
model |
Orientation of the model |
RTS |
Returns-to-scale for the model |
FareDEAsnfa
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | data(univariate)
dea.fit <- dea(univariate$x, univariate$y,
univariate$x, univariate$y,
model = "output",
RTS = "variable")
univariate$frontier <- univariate$y / dea.fit$thetaOpt
# Plot technical/allocative efficiency over time
library(ggplot2)
ggplot(univariate, aes(x, y)) +
geom_point() +
geom_line(aes(y = frontier), color = "red")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.