restriktor-package {restriktor}R Documentation

Package for equality and inequality restricted estimation, model selection and hypothesis testing

Description

Package restriktor implements estimation, testing and evaluating of linear equality and inequality restriktions about parameters and effects for univariate and multivariate normal models and generalized linear models.

Details

Package: restriktor
Type: Package
Version: 0.5-80
Date: 2024-07-05
License: GPL (>=2)
LazyLoad: yes

Function restriktor estimates the parameters of an univariate and multivariate linear model (lm), robust estimation of the linear model (rlm) or a generalized linear model (glm) subject to linear equality and/or inequality restriktions. The real work horses are the conLM, conMLM, the conRLM, and the conGLM functions. A major advantage of restriktor is that the constraints can be specified by a text-based description. This means that users do not have to specify the complex constraint matrix (comparable with a contrast matrix) themselves.

The function restriktor offers the possibility to compute (model robust) standard errors under the restriktions. The parameter estimates can also be bootstrapped, where bootstrapped standard errors and confidence intervals are available via the summary function. Moreover, the function computes the Generalized Order-restricted Information Criterion (GORIC), which is a modification of the AIC and a generalization of the ORIC.

The function iht (alias conTest) conducts restricted hypothesis tests. F, Wald/LRT and score test-statistics are available. The null-distribution of these test-statistics takes the form of a mixture of F-distributions. The mixing weights (a.k.a. chi-bar-square weights or level probabilities) can be computed using the multivariate normal distribution function with additional Monte Carlo steps or via a simulation approach. Bootstrap methods are available to calculate the mixing weights and to compute the p-value directly. Parameters estimates under the null- and alternative-hypothesis are available from the summary function.

The function goric (generalized order-restricted information criterion) computes GORIC values, weights and relative-weights or GORICA (generalized order-restricted information crittion approximation) values, weights and relative weights. The GORIC(A) values are comparable to the AIC values. The function offers the possibility to evaluate an order-restricted hypothesis against its complement, the unconstrained hypothesis or against a set of hypotheses. For now, only one order-restricted hypothesis can be evaluated against its complement but work is in progress to evaluate a set of order-restricted hypothesis against its complement.

The package makes use of various other R packages: quadprog is used for restricted estimation, boot for bootstrapping, ic.infer for computing the mixing weights based on the multivariate normal distribution, lavaan for parsing the constraint syntax.

Value

The output of function restriktor belongs to S3 class conLM, conMLM, conRLM or conGLM.

The output of function conTest belongs to S3 class conTest.

These classes offer print and summary methods.

Acknowledgements

This package uses as an internal function the function nchoosek from ic.infer, which is originally from vsn, authored by Wolfgang Huber, available under LGPL.

The output style of the iht print function is strongly inspired on the summary of the ic.test function from the ic.infer package.

Author(s)

Leonard Vanbrabant and Yves Rosseel - Ghent University

References

Groemping, U. (2010). Inference With Linear Equality And Inequality Constraints Using R: The Package ic.infer. Journal of Statistical Software, Forthcoming.

Kuiper R.M., Hoijtink H., Silvapulle M.J. (2011). An Akaike-type Information Criterion for Model Selection Under Inequality Constraints. Biometrika, 98, 495–501.

Kuiper R.M., Hoijtink H., Silvapulle M.J. (2012). Generalization of the Order-Restricted Information Criterion for Multivariate Normal Linear Models. Journal of Statistical Planning and Inference, 142, 2454–2463. doi:10.1016/j.jspi.2012.03.007.

Robertson T, Wright F, Dykstra R (1988). Order-Restricted Inference. Wiley, New York.

Schoenberg, R. (1997). Constrained Maximum Likelihood. Computational Economics, 10, 251–266.

Shapiro, A. (1988). Towards a unified theory of inequality-constrained testing in multivariate analysis. International Statistical Review 56, 49–62.

Silvapulle, M. (1992a). Robust tests of inequality constraints and one-sided hypotheses in the linear model. Biometrika, 79, 621–630.

Silvapulle, M. (1992b). Robust wald-type tests of one-sided hypotheses in the linear model. Journal of the American Statistical Association, 87, 156–161.

Silvapulle, M. (1996). Robust bounded influence tests against one-sided hypotheses in general parametric models. Statistics and probability letters, 31, 45–50.

Silvapulle, M.J. and Sen, P.K. (2005). Constrained Statistical Inference. Wiley, New York

Vanbrabant, L., Van Loey, N., and Kuiper, R.M. (2020). Evaluating a theory-based hypothesis against its complement using an AIC-type information criterion with an application to facial burn injury. Psychological methods, 25(2), 129-142. https://doi.org/10.1037/met0000238.

See Also

See also restriktor, iht, packages boot, goric, ic.infer, mvtnorm, and quadprog.

Examples

## Data preparation
## Ages (in months) at which an infant starts to walk alone.
DATA <- ZelazoKolb1972
DATA <- subset(DATA, Group != "Control")

## unrestricted linear model 
fit.lm <- lm(Age ~ -1 + Group, data = DATA)
summary(fit.lm)

## restricted linear model with restrictions that the walking 
## exercises would not have a negative effect of increasing the 
## mean age at which a child starts to walk. 

myConstraints <- ' GroupActive  < GroupPassive; 
                   GroupPassive < GroupNo '
                   
fit.con <- restriktor(fit.lm, constraints = myConstraints)
summary(fit.con)


[Package restriktor version 0.5-80 Index]