| .qp_refine | R Documentation |
After the Lagrangian projection handles smoothness equality constraints,
this function refines the estimate to satisfy additional inequality
constraints (monotonicity, derivative sign, range bounds, or user-supplied
constraints) via quadprog::solve.QP.
.qp_refine(
result,
X,
y,
K,
p_expansions,
A,
Lambda,
Lambda_block,
family,
iterate,
tol,
qp_Amat,
qp_bvec,
qp_meq,
qp_score_function,
order_list,
glm_weight_function,
schur_correction_function,
need_dispersion_for_estimation,
dispersion_function,
observation_weights,
VhalfInv,
...
)
result |
List of current coefficient column vectors by partition. |
X |
List of partition-specific design matrices. |
y |
List of response vectors by partition. |
K |
Integer; number of interior knots. |
p_expansions |
Integer; number of basis terms per partition. |
A |
Equality constraint matrix |
Lambda |
Shared penalty matrix |
Lambda_block |
Full block-diagonal penalty matrix. |
family |
GLM family object. |
iterate |
Logical; if |
tol |
Convergence tolerance. |
qp_Amat |
Inequality constraint matrix |
qp_bvec |
Inequality constraint vector |
qp_meq |
Number of equality constraints within |
qp_score_function |
Score function
|
order_list |
List of index vectors mapping partition rows to original data ordering. |
glm_weight_function |
Function computing GLM working weights. |
schur_correction_function |
Function computing Schur corrections. |
need_dispersion_for_estimation |
Logical. |
dispersion_function |
Dispersion estimation function. |
observation_weights |
List of observation weights by partition. |
VhalfInv |
Inverse square root of the working correlation matrix in
the original observation ordering (or |
... |
Passed to weight, correction, dispersion, and score functions. |
The subproblem at each iteration is a second-order Taylor approximation
of the penalized log-likelihood around the current iterate
\boldsymbol{\beta}^*. Collecting terms, this yields:
\tilde{\boldsymbol{\beta}} = \arg\min_{\boldsymbol{\beta}}
\left\{-\mathbf{d}^{\top}\boldsymbol{\beta} + \frac{1}{2}
\boldsymbol{\beta}^{\top}\mathbf{G}^{-1}\boldsymbol{\beta}\right\}
\quad \text{s.t.} \quad
\mathbf{A}^{\top}\boldsymbol{\beta} = \mathbf{0}, \quad
\mathbf{C}^{\top}\boldsymbol{\beta} \succeq \mathbf{c}
where \mathbf{d} is the score adjusted by the current iterate
and \mathbf{c} is the constraint value vector. Step acceptance
uses damped updates with deviance monitoring; see Nocedal and Wright
(2006) for the general SQP framework.
A list with components:
List of refined coefficient column vectors by partition.
List with QP solve metadata including Lagrangian multipliers and the active constraint matrix.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.