MGP_check {IMIFA} | R Documentation |
Check the validity of Multiplicative Gamma Process (MGP) hyperparameters
Description
Checks the hyperparameters for the multiplicative gamma process (MGP) shrinkage prior in order to ensure that the property of cumulative shrinkage (in expectation) holds, i.e. checks whether growing mass is assigned to small neighbourhoods of zero as the column index increases.
Usage
MGP_check(ad1,
ad2,
Q = 3L,
phi.shape = NULL,
phi.rate = NULL,
sigma.shape = NULL,
sigma.rate = NULL,
bd1 = 1,
bd2 = 1,
truncated = FALSE,
inverse = TRUE)
Arguments
ad1 , ad2 |
Shape hyperparameters for |
Q |
Number of latent factors. Defaults to |
phi.shape , phi.rate |
The shape and rate hyperparameters for the gamma prior on the local shrinkage parameters. Not necessary for checking if the cumulative shrinkage property holds, but worth supplying both if the actual a priori expected shrinkage factors are of interest. The default value(s) depends on the value of |
sigma.shape , sigma.rate |
The shape and rate hyperparameters for the gamma prior on the cluster shrinkage parameters. Not necessary for checking if the cumulative shrinkage property holds, but worth supplying both if the actual a priori expected shrinkage factors are of interest. The default value(s) depends on the value of |
bd1 , bd2 |
Rate hyperparameters for |
truncated |
A logical value indicating whether the version of the MGP prior based on left-truncated gamma distributions is invoked (see |
inverse |
Logical indicator for whether the cumulative shrinkage property is assessed against the induced Inverse Gamma prior, the default, or in terms of the Gamma prior (which is incorrect). This is always |
Details
This is called inside mcmc_IMIFA
for the "IFA"
, "MIFA"
, "OMIFA"
and "IMIFA"
methods. This function is vectorised with respect to the arguments ad1
, ad2
, phi.shape
, phi.rate
, sigma.shape
, sigma.rate
, bd1
and bd2
.
Value
A list of length 2 containing the following objects:
expectation |
The vector (or list of vectors) of actual expected a priori shrinkage factors. |
valid |
A logical (or vector of logicals) indicating whether the cumulative shrinkage property holds (in expectation). |
Note
It is recommended that ad2
be moderately large relative to ad1
, even if valid
can sometimes be TRUE
when this is not the case (e.g. when truncated=TRUE
). Similarly, satisfying this condition is no guarantee that valid
will be TRUE
, unless truncated=TRUE
. Therefore, a warning is returned if ad1 <= ad2
, regardless of the value taken by valid
, when truncated=FALSE
(the default).
Author(s)
Keefe Murphy - <keefe.murphy@mu.ie>
References
Murphy, K., Viroli, C., and Gormley, I. C. (2020) Infinite mixtures of infinite factor analysers, Bayesian Analysis, 15(3): 937-963. <doi:10.1214/19-BA1179>.
Durante, D. (2017). A note on the multiplicative gamma process, Statistics & Probability Letters, 122: 198-204.
Bhattacharya, A. and Dunson, D. B. (2011). Sparse Bayesian infinite factor models, Biometrika, 98(2): 291-306.
Zhang, X., Dunson, D. B., and Carin, L. (2011) Tree-structured infinite sparse factor model. In Getoor, L. and Scheffer, T. (Eds.), Proceedings of the 28th International Conference on Machine Learning (ICML 2011), June 28-July 2, 2011, Bellevue, WA, USA, pp. 785-792. Madison, WI, USA: Omnipress.
See Also
Examples
# Check if expected shrinkage under the MGP increases with the column index (WRONG approach!).
MGP_check(ad1=1.5, ad2=1.8, Q=10, phi.shape=3, inverse=FALSE)$valid #TRUE
# Check if the induced IG prior on the MGP column shrinkage parameters
# is stochastically increasing, thereby inducing cumulative shrinkage (CORRECT approach!).
MGP_check(ad1=1.5, ad2=1.8, Q=10, phi.shape=3, inverse=TRUE)$valid #FALSE
# Check again with a parameterisation that IS valid and examine the expected shrinkage values
(shrink <- MGP_check(ad1=1.5, ad2=2.8, Q=10, phi.shape=2, phi.rate=0.5, inverse=TRUE))
# Check previously invalid parameterisation again using truncated version of the MGP prior
MGP_check(ad1=1.5, ad2=1.8, Q=10, phi.shape=3, truncated=TRUE)$valid #TRUE