These functions are provided for compatibility with older versions of ‘sfaR’ only, and could be defunct at a future release.
lcmcross(
formula,
uhet,
vhet,
thet,
logDepVar = TRUE,
data,
subset,
weights,
wscale = TRUE,
S = 1L,
udist = "hnormal",
start = NULL,
whichStart = 2L,
initAlg = "nm",
initIter = 100,
lcmClasses = 2,
method = "bfgs",
hessianType = 1,
itermax = 2000L,
printInfo = FALSE,
tol = 1e-12,
gradtol = 1e-06,
stepmax = 0.1,
qac = "marquardt"
)# S3 method for lcmcross
print(x, ...)
# S3 method for lcmcross
bread(x, ...)
# S3 method for lcmcross
estfun(x, ...)
# S3 method for lcmcross
coef(object, extraPar = FALSE, ...)
# S3 method for summary.lcmcross
coef(object, ...)
# S3 method for lcmcross
fitted(object, ...)
# S3 method for lcmcross
ic(object, IC = "AIC", ...)
# S3 method for lcmcross
logLik(object, individual = FALSE, ...)
# S3 method for lcmcross
marginal(object, newData = NULL, ...)
# S3 method for lcmcross
nobs(object, ...)
# S3 method for lcmcross
residuals(object, ...)
# S3 method for lcmcross
summary(object, grad = FALSE, ci = FALSE, ...)
# S3 method for summary.lcmcross
print(x, digits = max(3, getOption("digits") - 2), ...)
# S3 method for lcmcross
efficiencies(object, level = 0.95, newData = NULL, ...)
# S3 method for lcmcross
vcov(object, ...)
A symbolic description of the model to be estimated based on
the generic function formula
(see section ‘Details’).
A one-part formula to account for heteroscedasticity in the one-sided error variance (see section ‘Details’).
A one-part formula to account for heteroscedasticity in the two-sided error variance (see section ‘Details’).
A one-part formula to account for technological heterogeneity in the construction of the classes.
Logical. Informs whether the dependent variable is logged
(TRUE
) or not (FALSE
). Default = TRUE
.
The data frame containing the data.
An optional vector specifying a subset of observations to be used in the optimization process.
An optional vector of weights to be used for weighted
log-likelihood. Should be NULL
or numeric vector with positive values.
When NULL
, a numeric vector of 1 is used.
Logical. When weights
is not NULL
, a scaling
transformation is used such that the weights
sums to the sample
size. Default TRUE
. When FALSE
no scaling is used.
If S = 1
(default), a production (profit) frontier is
estimated: \(\epsilon_i = v_i-u_i\). If S = -1
, a cost frontier is
estimated: \(\epsilon_i = v_i+u_i\).
Character string. Distribution specification for the one-sided
error term. Only the half normal distribution 'hnormal'
(Aigner
et al., 1977, Meeusen and Vandenbroeck, 1977) is currently
implemented.
Numeric vector. Optional starting values for the maximum likelihood (ML) estimation.
Integer. If 'whichStart = 1'
, the starting values
are obtained from the method of moments. When 'whichStart = 2'
(Default), the model is initialized by solving the homoscedastic pooled
cross section SFA model. 'whichStart = 1'
can be fast.
Character string specifying the algorithm used for
initialization and obtain the starting values (when 'whichStart = 2'
).
Only maxLik package algorithms are available:
'bfgs'
, for Broyden-Fletcher-Goldfarb-Shanno
(see maxBFGS
)
'bhhh'
, for Berndt-Hall-Hall-Hausman
(see maxBHHH
)
'nr'
, for Newton-Raphson (see maxNR
)
'nm'
, for Nelder-Mead - Default -
(see maxNM
)
'cg'
, for Conjugate Gradient
(see maxCG
)
'sann'
, for Simulated
Annealing (see maxSANN
)
Maximum number of iterations for initialization algorithm.
Default 100
.
Number of classes to be estimated (default = 2
). A
maximum of five classes can be estimated.
Optimization algorithm used for the estimation. Default =
'bfgs'
. 11 algorithms are available:
'bfgs'
,
for Broyden-Fletcher-Goldfarb-Shanno (see
maxBFGS
)
'bhhh'
, for
Berndt-Hall-Hall-Hausman (see maxBHHH
)
'nr'
, for Newton-Raphson (see maxNR
)
'nm'
, for Nelder-Mead (see maxNM
)
'cg'
, for Conjugate Gradient
(see maxCG
)
'sann'
, for Simulated
Annealing (see maxSANN
)
'ucminf'
, for a quasi-Newton type optimization with BFGS updating of
the inverse Hessian and soft line search with a trust region type monitoring
of the input to the line search algorithm
(see ucminf
)
'mla'
, for general-purpose optimization based on
Marquardt-Levenberg algorithm (see mla
)
'sr1'
, for Symmetric Rank 1 (see
trust.optim
)
'sparse'
,
for trust regions and sparse Hessian
(see trust.optim
)
'nlminb'
, for optimization using PORT routines (see
nlminb
)
Integer. If 1
(default), analytic Hessian is
returned. If 2
, bhhh Hessian is estimated (\(g'g\)).
Maximum number of iterations allowed for optimization.
Default = 2000
.
Logical. Print information during optimization. Default =
FALSE
.
Numeric. Convergence tolerance. Default = 1e-12
.
Numeric. Convergence tolerance for gradient. Default =
1e-06
.
Numeric. Step max for ucminf
algorithm. Default =
0.1
.
Character. Quadratic Approximation Correction for 'bhhh'
and 'nr'
algorithms. If 'qac = stephalving'
, the step length
is decreased but the direction is kept. If 'qac = marquardt'
(default), the step length is decreased while also moving closer to the pure
gradient direction. See maxBHHH
and
maxNR
.
an object of class lcmcross (returned by the function
lcmcross
).
additional arguments of frontier are passed to lcmcross; additional arguments of the print, bread, estfun, nobs methods are currently ignored.
an object of class lcmcross (returned by the function
lcmcross
).
Logical (default = FALSE
). If TRUE
, additional
parameters are returned (see coef
or vcov
).
Character string. Information criterion measure. Three criteria are available:
'AIC'
for Akaike information criterion
(default)
'BIC'
for Bayesian information criterion
'HQIC'
for Hannan-Quinn information criterion
.
Logical. If FALSE
(default), the sum of all
observations' log-likelihood values is returned. If TRUE
, a vector of
each observation's log-likelihood value is returned.
Optional data frame that is used to calculate the efficiency estimates. If NULL (the default), the efficiency estimates are calculated for the observations that were used in the estimation.
Logical. Default = FALSE
. If TRUE
, the gradient
for the maximum likelihood (ML) estimates of the different parameters is
returned.
Logical. Default = FALSE
. If TRUE
, the 95%
confidence interval for the different parameters (OLS or/and ML estimates) is
returned.
Numeric. Number of digits displayed in values.
A number between between 0 and 0.9999 used for the computation
of (in-)efficiency confidence intervals (defaut = 0.95
). Not used in the
case of lcmcross
.
The following functions are deprecated and could be removed from sfaR in a near future. Use the replacement indicated below:
lcmcross: sfalcmcross
bread.lcmcross: bread.sfalcmcross
coef.lcmcross: coef.sfalcmcross
coef.summary.lcmcross: coef.summary.sfalcmcross
efficiencies.lcmcross: efficiencies.sfalcmcross
estfun.lcmcross: estfun.sfalcmcross
fitted.lcmcross: fitted.sfalcmcross
ic.lcmcross: ic.sfalcmcross
logLik.lcmcross: logLik.sfalcmcross
marginal.lcmcross: marginal.sfalcmcross
nobs.lcmcross: nobs.sfalcmcross
print.lcmcross: print.sfalcmcross
print.summary.lcmcross: print.summary.sfalcmcross
residuals.lcmcross: residuals.sfalcmcross
summary.lcmcross: summary.sfalcmcross
vcov.lcmcross: vcov.sfalcmcross