vis_pval_distr_num_pat {GeneAccord} | R Documentation |
This function visualizes the distribution of p-values.
vis_pval_distr_num_pat(res_sim, output_pdf = "direct")
res_sim |
tibble containing the simulated pairs of genes/pathways.
It contains the columns 'num_patients',
and 'pval', and can be generated with
|
output_pdf |
The name of the pdf to be generated. Or if output_pdf is "direct", then the plot is generated directly and not to a pdf. Default: "direct" |
It is especially useful, when exploring the results with simulated
data under the null hypothesis, i.e. when delta is zero.
In that scenario, the p-values are expected to be uniformly distributed.
This function can take the p-values from
generate_test_stat_hist
where the concatenated tibble
contains different values for 'num_pat_pair',
i.e. the number of patients the simulated pairs are mutated in. The
input tibble is expected to have the two columns
'pval', and 'num_patients'. Left panel: histogram of all p-values from
the whole tibble.
Right panel: ecdf of the p-values with different colors for different
numbers of patients that the pairs were mutated in.
None, the function plots a p-value histogram.
Ariane L. Moore
res_sim <- dplyr::tibble(num_patients=c(rep(2,100), rep(3,100), rep(4,100)), pval=c(runif(300))) vis_pval_distr_num_pat(res_sim)