Learn R Programming

RegCombin (version 0.4.1)

compute_constraints: Compute the indexes of the values of the common regressors Xc used in the various shape constraints

Description

Compute the indexes of the values of the common regressors Xc used in the various shape constraints

Usage

compute_constraints(
  constraint,
  values,
  values_sel,
  indexes_k = NULL,
  nbV,
  grouped0,
  ind = NULL,
  c_sign = NULL
)

Value

a vector containing:

- the matrix R where each line is a constraint

- the matrices pp0 and pp1, which contains the indexes of the values of Xc in values_sel which enters the various constraints.

Arguments

constraint

the current shape constraint

values

the different unique points of support of the common regressor Xc.

values_sel

the selected values of Xc for the conditioning. Default is NULL.

indexes_k

indexes of the constraints

nbV

indexes of the constraints

grouped0

boolean indexing if the values of Xc have been changed

ind

index

c_sign

sign restrictions on the commonly observed regressors: -1 for a minus sign, 1 for a plus sign, 0 otherwise. Default is NULL, i.e. no constraints.