collapse_pp_trait: Collapse posterior probabilities of association for each...

Description Usage Arguments Value

View source: R/processing.R

Description

Combine the posterior probabilities for each individual trait/study according to the association patterns from which that trait comes from the alternative distribution. Provides the posterior probability of being associated with "at least trait X". Can also require non-null association with one or more traits and combine over patterns where both X and that/those trait(s) are from the alternative distribution.

Usage

1
collapse_pp_trait(post_prob, req_idx = NULL, prefix = "pp_")

Arguments

post_prob

matrix of posterior probabilities.

req_idx

(optional) scalar or integer vector of trait(s) where a non-null association is required (i.e. from the alternative distribution). If NULL, no traits will be required.

prefix

character string denoting prefix of column names for the results matrix.

Value

A numeric matrix of combined posterior probabilities.


kjgleason/primo documentation built on Sept. 7, 2021, 5:21 p.m.