Find effects that are significant in at least one condition

get_significant_results(m, thresh = 0.05, conditions = NULL, sig_fn = get_lfsr)

Arguments

m

the mash result (from joint or 1by1 analysis)

thresh

indicates the threshold below which to call signals significant

conditions

which conditions to include in check (default to all)

sig_fn

the significance function used to extract significance from mash object; eg could be ashr::get_lfsr or ashr::get_lfdr. (Small values must indicate significant.)

Value

a vector containing the indices of the significant effects, by order of most significant to least

Examples

simdata = simple_sims(50,5,1)
data = mash_set_data(simdata$Bhat, simdata$Shat)
m = mash(data, cov_canonical(data))
#>  - Computing 200 x 151 likelihood matrix.
#>  - Likelihood calculations took 0.00 seconds.
#>  - Fitting model with 151 mixture components.
#>  - Model fitting took 0.17 seconds.
#>  - Computing posterior matrices.
#>  - Computation allocated took 0.00 seconds.
get_significant_results(m)
#> effect_171 effect_160 effect_167 effect_193 effect_194 effect_157 effect_195 
#>        171        160        167        193        194        157        195 
#> effect_177 effect_198 effect_100 effect_192  effect_59 effect_179 
#>        177        198        100        192         59        179