getCharSTM1u: Computing Some Overall Characteristics in 'compContourM1u'

View source: R/getCharSTM1u.R

getCharSTM1uR Documentation

Computing Some Overall Characteristics in compContourM1u

Description

The function computes some overall characteristics of directional regression quantiles in the output of compContourM1u, namely the list COutST$CharST. It makes possible to obtain some useful information without saving any file on the disk, and it can be easily modified by the users according to their wishes.

Usage

getCharSTM1u(Tau, N, M, P, BriefDQMat, CharST, IsFirst)

Arguments

Tau

the quantile level in (0, 0.5).

N

the number of observations.

M

the dimension of responses.

P

the dimension of regressors including the intercept.

BriefDQMat

the method-specific matrix containing the rows of a potential individual output file corresponding to CTechST$BriefOutputI = 1. See the details below.

CharST

the output list, updated with each run of the function.

IsFirst

the indicator equal to one in the first run of getCharSTM1u (when CharST is initialized) and equal to zero otherwise.

Details

This function is called inside compContourM1u. First, it is called with BriefDQMat = NULL, CharST = NULL and IsFirst = 1 to initialize the output list CharST, and then it is called with IsFirst = 0 successively for the content of each potential output file corresponding to CTechST$BriefOutputI = 1, i.e., even if the output file(s) are not stored on the disk owing to CTechST$OutSaveI = 0.

It still remains to describe in detail the content of possible output files, describing the optimal conic segmentation of the directional space that lies behind the optimization problem involved.

If CTechST$BriefOutputI = 1, then the rows of such files are vectors of length 1+1+M+M+P+1 of the form c(ConeID, Nu, UVec, BDVec, ADVec, LambdaD) where

ConeID

is the number/order of the cone related to the line. If M > 2, then a cone can appear in the output repeatedly (under different numbers).

Nu

is the number of corresponding negative residuals.

UVec

is a normalized vector of the cone. It is usually its vertex direction but it may also be its interior vector pointing to a vertex of the artificial intersection of the cone with the bounding box [-1,1]^M. The max normalization is used if the breadth-first search algorithm is employed and the L2 normalization is used in the other case (when M = 2 and CTechST$D2SpecI = 1).

BDVec

is the vector c(b_1,...,b_M), i.e., the constant vector denominator of BVec, where BVec = BDVec/(t(BDVec)%*%UVec).

ADVec

is the vector c(a_1,...,a_P), i.e., the constant vector denominator of AVec, where AVec = ADVec/(t(BDVec)%*%UVec).

LambdaD

is the constant scalar denominator of Lambda = LambdaD/(t(BDVec)%*%UVec).

Recall that c(BVec, AVec) stands for the coefficients of the regression quantile hyperplane associated with UVec and that Lambda denotes the Lagrange multiplier equal to the optimal value Psi of the objective function for that direction.

If CTechST$BriefOutputI = 0, then the rows of the potential output file(s) are longer (of length 1+1+M+M+P+1+(P+M-1)*M+(P+M-1)) because they contain two more vectors appended at the end. The rows are of the form c(ConeID, Nu, UVec, BDVec, ADVec, LambdaD, vec(VUMat), IZ) where

VUMat

is the matrix for computing the multiplier vector MuR0Vec associated with zero residuals, MuR0Vec = (VUMat%*%UVec)/(t(BDVec)%*%UVec). That is to say that all directions from the interior of the cone result in the regression Tau-quantile hyperplanes containing the same P+M-1 observations because all such hyperplanes are the same up to a scaling factor multiplying their coefficients.

IZ

is the vector containing original indices of the M+P-1 observations with zero residuals for all directions from the interior of the cone.

Value

getCharSTM1u returns a list with the following components:

NUESkip

the number of (skipped) directions (and corresponding hyperplanes) artificially induced by intersecting the cones with the [-1,1]^M bounding box.

NAZSkip

the number of (skipped) hyperplanes (and corresponding directions) not counted in NUESkip and with at least one coordinate of AVec zero.

NBZSkip

the number of (skipped) hyperplanes (and corresponding directions) not counted in NUESkip and with at least one coordinate of BVec zero.

HypMat

(for M > 4) the component is missing
(for M <= 4) the matrix with M + P columns containing (in rows) all the distinct regression Tau-quantile hyperplane coefficients c(BVec, AVec) normalized with |BVec|, rounded to the eighth decimal digit, and sorted lexicographically. This matrix can be used for the computation of the regression Tau-quantile contour.

CharMaxMat

the matrix with the (slightly rounded) maxima of certain directional regression Tau-quantile characteristics over all remaining vertex directions.
If P = 1, then CharMaxMat has only three rows:
c(UVec, max(|BVec|)),
c(UVec, max(Lambda)), and
c(UVec, max(Lambda/|BVec|)),
respectively.
If P > 1, then the rows of CharMaxMat are as follows:
c(UVec, max(|BVec|)),
c(UVec, max(Lambda)),
c(UVec, max(Lambda/|BVec|)),
c(UVec, max(|c(a_2,...,a_P)|)),
c(UVec, max(|c(a_2,...,a_P)|/|BVec|)),
c(UVec, max(|a_2|)),
c(UVec, max(|a_2|/|BVec|)),
...,
c(UVec, max(|a_P|)), and
c(UVec, max(|a_P|/|BVec|)),
respectively. If P = 2, then the last two rows are missing for not being included twice.

CharMinMat

the matrix with the (slightly rounded) minima of certain directional regression Tau-quantile characteristics over all remaining vertex directions.
If P = 1, then CharMinMat has only three rows:
c(UVec, min(|BVec|)),
c(UVec, min(Lambda)), and
c(UVec, min(Lambda/|BVec|)),
respectively.
If P > 1, then CharMinMat has five rows:
c(UVec, min(|BVec|)),
c(UVec, min(Lambda)),
c(UVec, min(Lambda/|BVec|)),
c(UVec, min(|c(a_2,...,a_P)|)), and
c(UVec, min(|c(a_2,...,a_P)|/|BVec|)),
respectively.

Note that || symbolizes the Euclidean norm, and that the vertices (UVec) in the rows of CharMaxMat and CharMinMat are generally different and denote (one of) the direction(s) where the row maximum or minimum is attained.

Examples

##Run print(getCharSTM1u) to examine the default setting.

modQR documentation built on May 11, 2022, 5:18 p.m.

Related to getCharSTM1u in modQR...