hgt: Hard Graphical Thresholding Algorithm

Description Usage Arguments Details Value Note References Examples

View source: R/GGM.R

Description

Estimates sparse inverse covariance matrix.

Usage

1
hgt(x, size, active.entry = NULL, bcd.opt = list(max.iter = 10, eps = 0.001))

Arguments

x

There are 2 options: (1) x is an n by p data matrix; (2) a p by p sample covariance matrix. The program automatically identifies the input matrix by checking the symmetry. (n is the sample size and p is the dimension.)

size

A non-negative integer for determining the model size, i.e., the number of non-zero off-diagonal entries in the upper-triangular precision matrix, which is also the number of edges in the graph. size must range from 0 to (p^2 - p) / 2.

active.entry

Pre-determined non-zero off-diagonal entries positions of the precision matrix. Default: active.entry = NULL.

bcd.opt

A list of options that control details of the block coordinate descent algorithm.

Details

Hard Graphical Thresholding (HGT) algorithm proceeds by thresholding the sample correlation matrix and estimating the inverse covariance matrix with block coordinate descent algorithm. HGT algorithm could recover the inverse covariance matrix given model size or given active entries. When active entries are given directly, model fitting is the so-called covariance selection.

Value

A list with following components:

Omega

Estimated inverse covariance matrix.

active.entry

The position of the non-zero off-diagonal entries of Omega in the upper-triangular part.

Note

Either size or active.entry should be specified when function hgt is called. If both arguments are given, size would be omitted and the inverse covariance matrix would be estimated based on the given active.entry.

If arguments active.entry is specified, only one of the entries in symmetric positions should be given.

References

Luo, Shikai, Rui Song, and Daniela Witten (2014). Sure Screening for Gaussian Graphical Models. arXiv preprint arXiv:1407.7819. URL https://arxiv.org/abs/1407.7819.

Dempster, A.P. (1972). Covariance Selection. Biometrics, 28(1), 157-175. doi:10.2307/2528966

Examples

1
2
3
4
5
6
library(gif)

data("ar1")
p <- 100
non_zero_num <- sum(ar1[["Omega"]] != 0) - p
res <- hgt(ar1[["x"]], size = non_zero_num / 2)

gif documentation built on July 1, 2020, 8:53 p.m.