This function uses ecdf to calculate empirical p values given a null distribution and an observed distribution
The observed distribution
The null distribution
An empirical p value for each observed value
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.