plot.capr: Plot deviation diagnostics by component count
Description
For a fitted CAP regression, plots two diagnostics across the first
\(K\) components: (1) the negative log-likelihood returned by capr()
and (2) the log deviation-from-diagonality (DfD) for the loading matrix
formed by the first \(k\) directions. Both curves help assess the gain
from adding components.
Usage
# S3 method for capr
plot(x, ...)
Value
Invisibly returns the numeric vector of log deviation values (one per
component).
Arguments
x
A capr object returned by capr().
...
Additional arguments passed to graphics::plot() and applied to
both panels (for example, pch, col, or axis limits).
Details
The DfD criterion for the first \(k\) directions \(\Gamma^{(k)}\) is
$$\text{DfD}(\Gamma^{(k)}) =
\left(\prod_{i = 1}^{n}
\nu\!\left(\Gamma^{(k)\top} S_i \Gamma^{(k)} / T_i\right)^{T_i}
\right)^{1 / \sum_i T_i},$$
where
$$
\nu(A)=\frac{\det\{\mathrm{diag}(A)\}}{\det(A)}
$$ for a positive definite matrix \(A\).
The curve shows \(\log \text{DfD}(\Gamma^{(k)})\). A common choice for
\(k\) is the last point before a sudden jump in the negative
log-likelihood or log-DfD curve.