Description Usage Arguments Details Value
View source: R/visualisations.R
Creates a scatterplot of true effect sizes against estimated effect sizes.
1 2 3 4 5 6 7 8 9 | plot_estimates_vs_true(
dataset,
BETA,
P,
bonferroni,
true_effect,
save_plot_path = FALSE,
plot_filename = "beta_comparison.png"
)
|
dataset |
data imported to R by |
BETA |
column containing the estimated effect sizes from the analysis. State in the format dataset$BETA. |
P |
column containing the p-values from the analysis. State in the format dataset$P. |
bonferroni |
the column containing significance at bonferroni correction. State in the format dataset$bonferroni. |
true_effect |
the column containing the true effect sizes.
State in the format dataset$true_effect. Note: standard called 'beta' if
loaded by |
save_plot_path |
if |
plot_filename |
name of the file to be saved, including file extension. Must be either .pdf, .png or .jpeg |
In the plot an identity line is included, which helps visualise how well
the estimations compare to the true effect sizes.
Only SNPs with a p-value smaller than 0.05 are included in the plot.
The plot requires the user to run an analysis with
analysis_association()
, load the results and merge with
beta.txt
using load_results()
and augment results with
augment_results()
.
Either returns a ggplot
object or saves the plot to
save_plot_path
and returns NULL.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.