ic.est: Functions for order-restricted estimates and printing thereof

ic.estR Documentation

Functions for order-restricted estimates and printing thereof

Description

Function ic.est estimates a mean vector under linear inequality constraints, functions print.orest and summary.orest provide printed results in different degrees of detail.

Usage

ic.est(x, Sigma, ui, ci = NULL, index = 1:nrow(Sigma), meq = 0, 
            tol = sqrt(.Machine$double.eps))
## S3 method for class 'orest'
print(x, digits = max(3, getOption("digits") - 3), scientific = FALSE, ...)
## S3 method for class 'orest'
summary(object, display.unrestr = FALSE, brief = FALSE, 
            digits = max(3, getOption("digits") - 3), scientific = FALSE, ...)

Arguments

x

for ic.est: unrestricted vector (e.g. mean of a sample of random vectors), from which the expected value under linear inequality (and perhaps equality) restrictions is to be estimated

for print.orest: object of class orest (normally produced by ic.est or orlm)

object

for summary.orest: object of class orest (normally produced by ic.est or orlm)

Sigma

covariance or correlation matrix (or any multiple thereof) of x

ui

matrix (or vector in case of one single restriction only) defining the left-hand side of the restriction

ui%*%mu >= ci,

where mu is the expectation vector of x; the first few of these restrictions can be declared equality- instead of inequality restrictions (cf. argument meq); if only part of the elements of mu are subject to restrictions, the columns of ui can be restricted to these elements, if their index numbers are provided in index

Rows of ui must be linearly independent; in case of linearly dependent rows the function gives an error message with a hint which subset of rows is independent. Note that the restrictions must define a (possibly translated) cone, i.e. e.g. interval restrictions on a parameter are not permitted.

See contr.diff for examples of how to comfortably define various types of restriction.

ci

vector on the right-hand side of the restriction (cf. ui), defaults to a vector of zeroes

index

index numbers of the components of mu, which are subject to the specified constraints as ui%*%mu[index] >= ci

meq

integer number (default 0) giving the number of rows of ui that are used for equality restrictions instead of inequality restrictions.

tol

numerical tolerance value; estimates closer to 0 than tol are set to exactly 0

digits

number of digits to be used in printing

scientific

if FALSE, suppresses scientific representation of numbers (default: FALSE)

...

further arguments to print

display.unrestr

if TRUE, unrestricted estimate (i.e. object) is also displayed

brief

if TRUE, suppress printing of restrictions; default: FALSE

Details

Function ic.est heavily relies on package quadprog for determining the optimizer. It is a convenience wrapper for solve.QP from that package. The function is guaranteed to work appropriately if the specified restrictions determine a (translated) cone. In that case, the estimate is the projection along matrix Sigma onto one of the faces of that cone (including the interior as the face of the highest dimension); this means that it minimizes the quadratic form t(x-b)%*%solve(Sigma,x-b) among all b that satisfy the restrictions ui%*%b>=ci (or, if specified by meq, with the first meq restrictions equality instead of inequality restrictions).

Value

Function ic.est outputs a list with the following elements:

b.unrestr

x

b.restr

restricted estimate

Sigma

as input

ui

as input

ci

as input

restr.index

index of components of mu, which are subject to the specified constraints as in input index

meq

as input

iact

active restrictions, i.e. restrictions that are satisfied with equality in the solution, as output by solve.QP

Author(s)

Ulrike Groemping, BHT Berlin

See Also

See also ic.test, ic.weights, orlm, solve.QP

Examples

## different correlation structures
corr.plus <- matrix(c(1,0.9,0.9,1),2,2)
corr.null <- matrix(c(1,0,0,1),2,2)
corr.minus <- matrix(c(1,-0.9,-0.9,1),2,2)
## unrestricted vectors
x1 <- c(1, -1)
x2 <- c(-1, -1)
x3 <- c(10, -1)
## estimation under restriction non-negative orthant
## or first element equal to 0, second non-negative
ice <- ic.est(x1, corr.plus, ui=diag(c(1,1)), ci=c(0,0))
ice
summary(ice)
ice2 <-ic.est(x1, corr.plus, ui=diag(c(1,1)), ci=c(0,0), meq=1)
summary(ice2)
ic.est(x2, corr.plus, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x2, corr.plus, ui=diag(c(1,1)), ci=c(0,0), meq=1)
ic.est(x3, corr.plus, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x3, corr.plus, ui=diag(c(1,1)), ci=c(0,0), meq=1)
ic.est(x1, corr.null, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x1, corr.null, ui=diag(c(1,1)), ci=c(0,0), meq=1)
ic.est(x2, corr.null, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x2, corr.null, ui=diag(c(1,1)), ci=c(0,0), meq=1)
ic.est(x3, corr.null, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x3, corr.null, ui=diag(c(1,1)), ci=c(0,0), meq=1)
ic.est(x1, corr.minus, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x1, corr.minus, ui=diag(c(1,1)), ci=c(0,0), meq=1)
ic.est(x2, corr.minus, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x2, corr.minus, ui=diag(c(1,1)), ci=c(0,0), meq=1)
ic.est(x3, corr.minus, ui=diag(c(1,1)), ci=c(0,0))
ic.est(x3, corr.minus, ui=diag(c(1,1)), ci=c(0,0), meq=1)
## estimation under one element restricted to being non-negative
ic.est(x3, corr.plus, ui=1, ci=0, index=1)
ic.est(x3, corr.plus, ui=1, ci=0, index=2)

ic.infer documentation built on Oct. 5, 2023, 5:09 p.m.