p_empirical_from_tally: Tally p-values from permuted null model to enable calculation...

View source: R/tally_p_null.R

p_empirical_from_tallyR Documentation

Tally p-values from permuted null model to enable calculation of empirical p-values

Description

Tally p-values from permuted null model to enable calculation of empirical p-values

Usage

p_empirical_from_tally(p_null_tallies, scaffold_ID, min_n_permutations)

Arguments

p_null_tallies

a matrix containing tallies of null p-values above or below the initial p-value

scaffold_ID

a string or numeric value indicating the scaffold, to be used only for labeling output

min_n_permutations

Integer, the minimum number of permutations needed to calculate the empirical p-value out to the desired number of significant figures

Value

A dataframe with four columns, for 1) scaffold ID, 2) SNP window position, 3) p-values from the model used in SKAT without resampling, and 4) empirical p-values

Examples

data("sample_p_null_tallies")
p_empirical_from_tally(p_null_tallies = sample_p_null_tallies,
                       scaffold_ID = 10,
                       min_n_permutations = 1e5)

naglemi/mtmcskat documentation built on Aug. 23, 2023, 5:35 p.m.