alternative_determine_hyperparameters: Functioning for automatically determining MASSIVE...

Description Usage Arguments Value Examples

View source: R/utils.R

Description

Functioning for automatically determining MASSIVE hyperparameters from data. where we assume a N(0, sd_slab) prior on skappa_X.

Usage

1

Arguments

J

Integer number of candidate instruments.

N

Integer number of observations.

SS

Numeric matrix containing first- and second-order statistics.

sigma_G

Numeric vector of instrument standard deviations.

Value

List containing sd_slab and sd_spike hyperparameters, indicating the standard deviation of the slab and spike component, respectively.

Examples

1
2
3
4
5
J <- 5 # number of instruments
N <- 1000 # number of samples
par <- random_Gaussian_parameters(J)
dat <- generate_data_MASSIVE_model(N, n = 2, p = rep(0.3, J), par)
alternative_determine_hyperparameters(J, N, dat$SS, binomial_sigma_G(dat$SS))

igbucur/MASSIVE documentation built on Oct. 26, 2020, 1:26 a.m.