la.golazo: This is a wrapper for the dual maximum likelihood GOLAZO...

Description Usage Arguments Value Examples

View source: R/la.golazo.R

Description

The function simply running golazo() with L_ij=-Inf and U_ij=0 (for certain ij).

Usage

1
la.golazo(K, edges = "input", tol = 1e-07, verbose = TRUE)

Arguments

K

Positive semidefinite matrix. This will be typically the inverse of the sample covariance matrix or the output of a previous GOLAZO run.

edges

It takes three possible values: "all", "input" (default), or it is equal to an adjacency matrix. If it is equal to input teh algorithm first finds the non-zero entries of the input matrix K and onnly the corresponding entries of Sigma are assumed nonnegative. If edges is equal to "all" all entries of Sigma are bound to be nnonnegative. This corresponds to computing the MLE under (positively) associated distributions. Finally, edges equal to any adjacency matrix (1 for edges, 0 otherwise) allows to connstraint arbitrary entries of Sigma to be nonnegative.

tol

The convergence tolerance (default tol=1e-7). The algorithm termininnates when teh dual gap (guaranteed to be nonnegative) is less than tol.

verbose

if TRUE (default) the output will be printed.

Value

Sig the optimal value of the covariannce matrix

K the optimal value of the concentration matrix

it the number of iterations

Examples

1
2
3
4
5
6
7
data(ability.cov)
S <- ability.cov$cov
R <- stats::cov2cor(S)
d <- nrow(R)
res <- positive.golazo(R,rho=0.1)
res2 <- la.golazo(res$K)
print(res2$Sig)

pzwiernik/golazo documentation built on Aug. 13, 2020, 4:15 p.m.