compute_taxon_specific_latent_trait_elbo: Taxon Specific Latent Trait Trait ELBO

View source: R/cavi_latent_traits.R

compute_taxon_specific_latent_trait_elboR Documentation

Taxon Specific Latent Trait Trait ELBO

Description

Compute the contribution of taxon specific latent traits to the Evidence Lower Bound (ELBO) of a PLVM given the approximate posterior distribution for loadings and latent traits

Usage

compute_taxon_specific_latent_trait_elbo(
  taxon_specific_latent_trait_expectation,
  taxon_specific_latent_trait_outer_product_expectation,
  taxon_specific_latent_trait_covariance,
  phy,
  phylogenetic_gp,
  perform_checks = TRUE
)

Arguments

taxon_specific_latent_trait_expectation

A (2S - 1)xL matrix of real values. The expected value of the taxon specific latent traits.

taxon_specific_latent_trait_outer_product_expectation

A LxLx(2S - 1) array of real values. The expected outer product of taxon specific latent traits under the approximate posterior.

taxon_specific_latent_trait_covariance

A LxLx(2S - 1) array of real values. The covariance of taxon specific latent traits under the approximate posterior.

phy

An object of class "phylo".

phylogenetic_gp

A (2S - 1)x2xL array of real values. Hyperparameters for the Gaussian process over phy.

perform_checks

Logical. Check if function inputs are specified correctly.

Value

A real valued scalar. The contribution of taxon specific latent traits to the ELBO.


jpmeagher/vbar documentation built on Nov. 22, 2022, 5:48 a.m.